Class: EJX::Template::String

Inherits:
Object
  • Object
show all
Defined in:
lib/ejx/template/string.rb

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ String

Returns a new instance of String.



5
6
7
# File 'lib/ejx/template/string.rb', line 5

def initialize(value)
  @value = value
end

Instance Method Details

#to_jsObject



9
10
11
# File 'lib/ejx/template/string.rb', line 9

def to_js
  JSON.generate(@value)
end