Created
October 8, 2019 19:12
-
-
Save mikaelbr/421fcad5bb90e0f889ebbaa0a8c0b7fb to your computer and use it in GitHub Desktop.
Code for blogpost "Using JSX for your own lightweight declarative library"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "jsx-demo", | |
"version": "1.0.0", | |
"main": "index.js", | |
"scripts": { | |
// Using the babel CLI specify our single file (could be pattern) | |
// and output in dist directory | |
"build": "babel index.js -d dist" | |
}, | |
"devDependencies": { | |
// Installing the CLI it self with core module and the JSX plugin | |
"@babel/cli": "^7.6.2", | |
"@babel/core": "^7.6.2", | |
"@babel/plugin-transform-react-jsx": "^7.3.0" | |
}, | |
"babel": { | |
// Transform JSX syntax using the babel plugin | |
"plugins": ["@babel/plugin-transform-react-jsx"] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment