Last active
May 13, 2018 13:47
-
-
Save jonathanconway/15271dda82b1de39e12eb938ac4a6e8d to your computer and use it in GitHub Desktop.
Minimalist create-react-app. Just enough to write a failing unit-test. π΄ β
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
################################################################################ | |
# | |
# 1. Save this file to /usr/local/bin | |
# | |
# 2. To make it executable: chmod u+x /usr/local/bin/create-react-app-minimal.sh | |
# | |
# 3. To create your app: create-react-app-minimal {app-name} | |
# | |
# 4. In your package.json, change this line: | |
# "test": ... | |
# to this: | |
# "test": "jest" | |
# | |
# 5. And append this block: | |
# , | |
# "babel": { | |
# "presets": [ | |
# "env", | |
# "react" | |
# ], | |
# "plugins": [ | |
# "transform-class-properties", | |
# "transform-object-rest-spread", | |
# "transform-runtime" | |
# ] | |
# } | |
# | |
################################################################################ | |
mkdir $1 | |
cd $1 | |
npm init -y | |
npm install \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
babel-preset-react6.24.1 \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
[email protected] \ | |
--save-dev | |
npm install \ | |
[email protected] \ | |
[email protected] \ | |
--save |
Thanks for your feedback, @MichaelDimmitt. I'll see if I can resolve this. I also want to try and avoid spelling out the version numbers if possible, so that it picks up the latest version instead. Will work on a fix.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
thank you for posting a minimalist version.
I am spending my day playing around with this as a base.
I think you have a typo. @jonathanconway
not working:
babel-preset-react6.24.1
npm ERR! 404 Not Found: babel-preset-react6.24.1@latest
working:
[email protected]
Thoughts?