babel-plugin-convert-to-json
Convert various file formats to json on import. Very much so a work in progress, currently supports .yml
and .env
files
Example
In
Out
const yml = <JSON>const env = <JSON>
Installation
$ npm install babel-plugin-convert-to-json
Usage
.babelrc
(Recommended)
Via .babelrc
Via CLI
$ babel --plugins convert-to-json script.js
Via Node API
;