module TypeScript::Source
Constants
- COMPILE_FUNCTION_SOURCE
Public Class Methods
contents()
click to toggle source
# File lib/type_script.rb, line 25 def self.contents @contents ||= File.read(path) + COMPILE_FUNCTION_SOURCE end
context()
click to toggle source
# File lib/type_script.rb, line 29 def self.context @context ||= ExecJS.compile(contents) end
path()
click to toggle source
# File lib/type_script.rb, line 10 def self.path @path ||= ENV['TYPESCRIPT_SOURCE_PATH'] || bundled_path end
path=(path)
click to toggle source
# File lib/type_script.rb, line 14 def self.path=(path) @contents = @version = @context = nil @path = path end