Skip to content

Commit 3de260a

Browse files
committed
chore: add time to transpile to output
1 parent a7f0487 commit 3de260a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Diff for: src/vm.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,10 @@ export default async function initVM() {
6969
options = {using:}
7070
options[:rewriters] = Language.rewriters.select { |rw| rw.unsupported_version?(version) } + custom_rewriters
7171
72+
start = Time.now
7273
source = Language.transform(code, **options)
73-
source += "\n # Transformed with RubyNext v#{RubyNext::VERSION} for Ruby #{version}"
74+
time = Time.now - start
75+
source += "\n # Transformed with RubyNext v#{RubyNext::VERSION} for Ruby #{version} (took #{time}s)"
7476
end
7577
end
7678
`);

0 commit comments

Comments
 (0)