Skip to content

Instantly share code, notes, and snippets.

@EdwardIII

EdwardIII/f.rb Secret

Created February 23, 2021 14:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EdwardIII/a4423a48bc5131fa77825bf34c1dfc95 to your computer and use it in GitHub Desktop.
Save EdwardIII/a4423a48bc5131fa77825bf34c1dfc95 to your computer and use it in GitHub Desktop.
filename = 'contract.erb.html' # @arg1 and @arg2 are used in example.rhtml
erb = ERB.new(File.read(filename))
erb.filename = filename
Contract = erb.def_class(Contract_, 'render()')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment