asmblah/uniter

CLI tooling

Opened this issue · 2 comments

Hey.

I have completed my concept for the WebPack loader. It wont be easy to make but I have a plan for it.

However, in order to be able to see the results of various statement compilations, I need to be able to dump the generated source. That is, where I thought, the CLI would come in handy.

Currently, the Uniter command is pretty simple - it grabs a file and runs it.

These features would be nice, if it would have them:

  • Output transpiled JS code.
  • script to run before the actual Uniter starts, allowing the script to install functions and such.
  • Specifying sync or async mode.
--dump-js | Dump the generated JavaScript to STDOUT.
--before <script> | Script to run before Uniter.
--mode=sync/async | Specify mode

What do you think?

Sounds great to me, I'm planning to add these features for you soon. 👍

Just as an update on this one:

--dump-js | Dump the generated JavaScript to STDOUT.

we have --transpile-only for this, hope it does what you need!


--before <script> | Script to run before Uniter.

this is interesting - not currently available, but would definitely be useful


--mode=sync/async | Specify mode

we currently have async as the default mode, and the --sync option is available to switch to synchronous mode. However, especially now that we have psync mode too, it would be good to have an option --mode=[async|psync|sync] as you originally suggested @IngwiePhoenix!