diff --git a/lib/babel/transpiler.rb b/lib/babel/transpiler.rb index 71728be..2b14a20 100644 --- a/lib/babel/transpiler.rb +++ b/lib/babel/transpiler.rb @@ -21,7 +21,7 @@ def self.script_path end def self.context - @context ||= ExecJS.compile("var self = this; " + File.read(script_path)) + @context ||= ExecJS.compile("var self = this; " + File.read(script_path, encoding: 'utf-8')) end def self.transform(code, options = {})