Hi John,
It seems that node-jxa uses browserify to generate a single script file each time it is invoked. For scripts that are called often, or that are substantial in size, this is quite a bit of overhead.
So I was wondering whether the node-jxa command could accept an option that changes its behaviour to instead generate a .scpt file using osacompile command. This .scpt file can then be used and shared as like any other applescript, but also isn't regenerated on each invocation.
Perhaps a -c option which takes a file path for the resulting compiled .scpt file.
I hope this makes sense?
Is this something you would consider adding to this great tool?
Many thanks.
Damo.
Hi John,
It seems that node-jxa uses browserify to generate a single script file each time it is invoked. For scripts that are called often, or that are substantial in size, this is quite a bit of overhead.
So I was wondering whether the node-jxa command could accept an option that changes its behaviour to instead generate a .scpt file using
osacompilecommand. This .scpt file can then be used and shared as like any other applescript, but also isn't regenerated on each invocation.Perhaps a
-coption which takes a file path for the resulting compiled .scpt file.I hope this makes sense?
Is this something you would consider adding to this great tool?
Many thanks.
Damo.