docs: recommend browserify transforms

This commit is contained in:
Yoshua Wuyts
2016-05-24 22:11:21 +09:00
parent 1f573e5049
commit ef23323483
+12
View File
@@ -608,6 +608,18 @@ Consider running some of the following:
- [bulkify](https://www.npmjs.com/package/bulkify) - transform inline - [bulkify](https://www.npmjs.com/package/bulkify) - transform inline
[bulk-require](https://www.npmjs.com/package/bulk-require) calls into [bulk-require](https://www.npmjs.com/package/bulk-require) calls into
statically resolvable require maps statically resolvable require maps
- [envify](https://github.com/hughsk/envify) - replace `process.env` values
with plain strings
Generally for production builds you'll want to run:
```sh
$ NODE_ENV=production browserify \
-t envify \
-t unassertify \
-t es2020 \
-t uglifyify \
| uglifyjs
```
## Hey, doesn't this look a lot like Elm? ## Hey, doesn't this look a lot like Elm?
Yup, it's greatly inspired by the `elm` architecture. But contrary to `elm`, Yup, it's greatly inspired by the `elm` architecture. But contrary to `elm`,