This is a
playground to test code. It runs a full
Node.js environment and already has all of
npm’s 400,000 packages pre-installed, including
tnode with all
npm packages installed. Try it out:
This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.
tnode is a very light wrapper around your
node executable that strips Flow type annotation syntax from your code before
calling into node.
You use it exactly like the regular
tnode invokes a node instance with a patched
function, which strips type annotations from your code.
Under the hood, this command:
$ tnode foo.js all the args
Turns into something like this:
$ TNODE_ENTRY_POINT=foo.js node fallback.js all the args
tnode executable via npm:
$ npm install -g tnode
You can also just
require('tnode') in a script _without any annotations, and
require() any other .js file that has annotations after that.
require('tnode'); var wow = require('./someTypedCode'); // etc…
This is a fork of
gnode that is
modified to work with Flow type syntax.