escodegen.jsx
v0.1.0
Published
escodegen wrapper for JSX
Downloads
18
Readme
escodegen.jsx
Synopsis
escodegen wrapper for JSX.
Code Example
import "escodegen.jsx";
import "esprima.jsx";
import "console.jsx";
import "js/nodejs.jsx";
class _Main {
static function main(argv : string[]) : void
{
var src = node.fs.readFileSync(argv[0]);
console.log(escoegen.generate(esprima.parse(src)));
}
}
Installation
If you want to use this library from other project, install like the following:
$ npm install escodegen.jsx esprima.jsx --save-dev
$ npm install escodegen --save
It needs esprima.jsx and escodegen to use.
or add like these lines to your parent project's package.json
:
devDependencies: {
"escodegen.jsx": "~0.1.0"
},
peerDepenencies: {
"escodegen.jsx": "~0.1.0"
}
API Reference
escodegen.generate(esprimatoken) : string
Dump source code in string. It doesn't support escodegen's option yet.
Development
Repository
- Repository: git://github.com/shibukawa/escodegen.jsx.git
- Issues: https://github.com/shibukawa/escodegen.jsx/issues
Run Test
$ grunt test
Build Sample
$ grunt build
Generate API reference
$ grunt doc
Author
- shibukawa / [email protected]
License
BSD-2-Clause
Complete license is written in LICENSE.md
.