Skip to content

Instantly share code, notes, and snippets.

@zeknas

zeknas/.babelrc

Last active Feb 15, 2017
Embed
What would you like to do?
hyperapp + jsx + browserify minimal boilerplate #tags: hyperapp
{
"presets": ["es2015"],
"plugins": [
[
"transform-react-jsx",
{
"pragma": "h"
}
]
]
}
<!doctype html>
<html>
<body>
<script src="bundle.js"></script>
</body>
</html>
import { h, app } from "hyperapp"
app({
model: "Hi.",
view: model => <h1>{model}</h1>
})
{
"name": "hyperapp-jsx-browserify-starter",
"version": "0.0.0",
"description": "HyperApp+JSX+Browserify",
"main": "index.js",
"dependencies": {
"hyperapp": "*"
},
"devDependencies": {
"babel-plugin-transform-react-jsx": "^6.22.0",
"babel-preset-latest": "^6.22.0",
"babelify": "^7.3.0",
"browserify": "^14.0.0",
"bundle-collapser": "^1.2.1",
"uglifyify": "^3.0.4",
"uglifyjs": "^2.4.10"
},
"scripts": {
"test": "exit 1",
"build": "browserify -t babelify index.js -g uglifyify -p bundle-collapser/plugin | uglifyjs > bundle.js"
},
"keywords": [
"hyperapp"
],
"author": "Jorge Bucaran",
"license": "MIT"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment