We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 45fd7dd commit e75f22fCopy full SHA for e75f22f
1 file changed
lib/jammit/compressor.rb
@@ -98,7 +98,7 @@ def compile_jst(paths)
98
base_path = find_base_path(paths)
99
compiled = paths.map do |path|
100
contents = read_binary_file(path)
101
- contents = contents.gsub(/\n/, '').gsub("'", '\\\\\'')
+ contents = contents.gsub(/\r?\n/, '').gsub("'", '\\\\\'')
102
name = template_name(path, base_path)
103
"#{namespace}['#{name}'] = #{Jammit.template_function}('#{contents}');"
104
end
0 commit comments