babel-plugin-precompile-charcodes
Convert character code getters into plain integers.
Install
With npm do:
npm install babel-plugin-precompile-charcodes --save-dev
Example
Convert str.charCodeAt(0)
to a plain integer, useful for parsers/tokenizers.
Input
const at = '@';
Output
const at = 64;
Usage
In your Babel configuration:
Contributors
Thanks goes to these wonderful people (emoji key):
Ben Briggs 💻 📖 👀 ⚠️ |
---|
This project follows the all-contributors specification. Contributions of any kind welcome!
License
MIT © Ben Briggs