Skip to content

Revert 1 master #957

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 248 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
248 commits
Select commit Hold shift + click to select a range
4b110c4
Clarify why we only need css?-autoprefixer in development
gaearon Aug 5, 2016
3fe65ee
add shebang to tasks scripts (#376)
apaleslimghost Aug 5, 2016
ecacd55
Tweak Jest default settings (#378)
gaearon Aug 5, 2016
8ad2dcc
Fixed typo (#382)
Nopik Aug 6, 2016
46fe4a6
Creating a new app in the current directory (#368)
torifat Aug 8, 2016
73a116e
Update package.json (#397)
A-gambit Aug 8, 2016
0af7262
Add Object.assign() polyfill (#399)
gaearon Aug 8, 2016
9488674
Bump case-sensitive-paths-webpack-plugin
gaearon Aug 8, 2016
4b39705
Add Surge.sh to deploy instructions (#379)
elboman Aug 8, 2016
975b2ba
Allow popular test path conventions (#400)
gaearon Aug 8, 2016
2dbab0b
Make build output more chill
gaearon Aug 8, 2016
2397413
Make missing module output slimmer
gaearon Aug 8, 2016
078e011
Add React Native Web support (#407)
grigio Aug 9, 2016
905157a
Disable dot rule of connect-history-api-fallback (#422)
mxstbr Aug 11, 2016
799131f
Load favicon through html-loader. (#428)
andreypopp Aug 12, 2016
598cdb3
Add a hash to media files even in the devmode. (#446)
arunoda Aug 15, 2016
a32afd3
add otf font format to loaders (#434)
A-gambit Aug 18, 2016
4ad0b42
Deactivate the `new-cap` rule in ESLint (#470)
rricard Aug 22, 2016
70e4e24
Add 0.2.2 changelog (#475)
gaearon Aug 22, 2016
34a849e
Add migration instructions
gaearon Aug 22, 2016
9b6c1fb
Link to Heroku article
gaearon Aug 22, 2016
6c17901
Added support for webp images in #442 (#458)
gafemoyano Aug 23, 2016
2af565c
Clarify "homepage" field has special meaning
gaearon Aug 23, 2016
fe7af21
Correcting typo on README.md (#479)
GautierT Aug 24, 2016
00f0625
Clarify 0.3.0 is not out yet
gaearon Aug 25, 2016
b5fee9b
Fix default package version added by global CLI (#491)
kripod Aug 25, 2016
4769fcc
Use most recent React version (#477)
wdhorton Aug 25, 2016
2f6a2c5
Add missing Changelog entry—thanks @elijahmanor!
gaearon Aug 25, 2016
3ca516b
Started using babel-preset-latest (#490)
kripod Aug 25, 2016
f6b7cb2
Prepare for 0.2.3 release
gaearon Aug 25, 2016
07acaff
Update CHANGELOG.md (#492)
gaearon Aug 25, 2016
b2b0ddc
Mark react-scripts as executable
gaearon Aug 28, 2016
bf26f63
Allow importing static file outside src and node_modules folders (#504)
fson Aug 28, 2016
5428318
Add tarec to the alternatives (#516)
geowarin Aug 29, 2016
9f65211
Add instructions on <meta> tags
gaearon Aug 31, 2016
1e60509
Add a link back to CRA
gaearon Aug 31, 2016
7b86b81
ignore .idea folder (#522)
denofevil Aug 31, 2016
3901d7c
Add a more prominent link to the guide (#524)
fson Aug 31, 2016
4335f03
Typo fix (#526)
coryhouse Aug 31, 2016
f994f3b
removing no-return-assign lint rule (#528) (#529)
mrscobbler Aug 31, 2016
6be8ae0
Update Jest (#530)
gaearon Sep 1, 2016
50f4a03
0.3.0-beta
gaearon Sep 1, 2016
f148a34
Enable watch implicitly unless on CI (#533)
gaearon Sep 1, 2016
63197c4
Disable react-constant-elements because of bugs (#534)
gaearon Sep 1, 2016
c2a56cb
Resolve babel-runtime relative to the config (#535)
gaearon Sep 1, 2016
452dd28
Remove unnecessary describe()
gaearon Sep 1, 2016
365d990
Update deps
gaearon Sep 1, 2016
7c2d214
Document testing (#538)
gaearon Sep 1, 2016
538244e
Add 0.3.0 changelog (#539)
gaearon Sep 1, 2016
3cc0301
0.3.0
gaearon Sep 1, 2016
5e58c48
Ignore coverage folder generated by jest (#541)
ldesplat Sep 2, 2016
35dffd7
Small testing docs tweaks. (#540)
cpojer Sep 2, 2016
48b2574
Bump Jest
gaearon Sep 2, 2016
73de4ce
0.3.1
gaearon Sep 2, 2016
4b9b665
Add 0.3.1 to changelog
gaearon Sep 2, 2016
91388a5
Update CONTRIBUTING.md
gaearon Sep 2, 2016
df7e07b
Explain focusing and excluding tests
gaearon Sep 2, 2016
9c45a27
Update CONTRIBUTING.md
gaearon Sep 2, 2016
9d38924
Fix some typos (#547)
maxdeviant Sep 2, 2016
6cf7157
tagging dev-only code (@remove-on-publish-begin/end) and pre-eject-on…
Jiansen Sep 2, 2016
4fd7aa8
Clarify some of the comments
gaearon Sep 2, 2016
1d6a1e4
Made webpack respect NODE_PATH environment variable
Aug 22, 2016
735793b
Removed NODE_PATH from env.js
Aug 22, 2016
eaf0bc3
Added ability to specify multiple directories in node_path.
Aug 23, 2016
f8124d9
Tweak how NODE_PATH is handled
gaearon Sep 2, 2016
4672b3f
Add Modulus to list of deployment options (#416)
theworkflow Sep 2, 2016
a35e23d
Reorder deployment instructions by alphabet + minor tweaks
gaearon Sep 2, 2016
3b14357
Add src/setupTests.js to specify environment setup for Jest (#545) (#…
gaelollivier Sep 2, 2016
0ff0619
Remove code that is unused after publish (#550)
gaearon Sep 2, 2016
473ef3a
Disable implicit serving of the source files (#551)
gaearon Sep 2, 2016
3e5de63
Look for HTTPS environment variable (#430)
dceddia Sep 2, 2016
31ef990
Add 0.4.0 changelog
gaearon Sep 2, 2016
0561da1
0.4.0
gaearon Sep 2, 2016
848d8a3
Mention npm test in init output
gaearon Sep 2, 2016
6aa3e1f
Clarify proxy instructions in generated app README (#537)
Sep 2, 2016
92518ed
Fix tasks
gaearon Sep 2, 2016
1282a06
Fix typo
gaearon Sep 2, 2016
e7bcb69
fix typo setupTest.js -> setupTests.js (#555)
Sep 2, 2016
e0f4e61
Fix version in CHANGELOG npm install command (#557)
ericf Sep 3, 2016
a79c38c
Provide custom onError handler for http-proxy-middleware (#502)
cloudmu Sep 3, 2016
3485f29
Add missing breaking change description from 0.3.0 (#562)
gaearon Sep 3, 2016
2b31355
Fix e2e test (#561)
gaearon Sep 3, 2016
e17316f
Document #564
gaearon Sep 3, 2016
50a0a5a
Adds JSX extension support (#563)
tizmagik Sep 3, 2016
0865592
Fix local end-to-end testing flow (#566)
gaearon Sep 3, 2016
f579855
Add 0.4.1 changelog
gaearon Sep 3, 2016
bf5298d
0.4.1
gaearon Sep 3, 2016
2d4048e
Update Flow instructions (#567)
gaearon Sep 3, 2016
ef2c972
Add a note on decorators
gaearon Sep 3, 2016
a695168
Send proper error response in custom onError handler for httpProxyMid…
cloudmu Sep 5, 2016
35d0d44
Warn about unsupported Node.js versions (#575)
fson Sep 6, 2016
3ffe8c5
Fix mocking assets with special characters in the file path (#584)
fson Sep 10, 2016
aad08e2
Avoid tons of *.json.gzip-files created in project root when running …
thangngoc89 Sep 10, 2016
f81ccab
Add support for *.jpeg file extension. (#624)
mareksuscak Sep 11, 2016
6e6cacd
Bump case-sensitive-paths-webpack-plugin version (#593)
Urthen Sep 11, 2016
fa674df
Improve the output of scripts/init.js (#629)
btnwtn Sep 11, 2016
12d0224
Update eject message
fson Sep 11, 2016
8808a97
Check the app name before proceeding. (#628)
mareksuscak Sep 11, 2016
1ab8a2e
Make User Guide stand out more
gaearon Sep 12, 2016
13306cf
Readme: Relative links are broken in lists (GitHub bug?)
gaearon Sep 12, 2016
75bd89c
Fixed typo in code comment (#635)
wakooka Sep 13, 2016
d73ae0b
Readme: add Travis-CI badge so people can easily see there is tests (…
MoOx Sep 14, 2016
e497116
Remove eslintConfig from package.json (#649)
fson Sep 14, 2016
d516a4a
Add kyt as an alternative
gaearon Sep 15, 2016
6182bb1
Bump webpack-dev-server to version 1.15.2 to fix #574 (#652)
dceddia Sep 16, 2016
a5312e2
Resolve app paths from realpath of CWD, fix #637 (#648)
motiz88 Sep 16, 2016
172bf38
Exempt variables prefixed with underscore from no-unused-vars rule (#…
valscion Sep 16, 2016
10effea
Add ES5 version of `path-exists` to CLI
Sep 10, 2016
5d2c799
Update file structure in README (#664)
sstruct Sep 17, 2016
50ced25
Corrected a typo in the comments of start.js (#663)
ancyrweb Sep 17, 2016
48b2d3e
add audio support (#665)
danharper Sep 17, 2016
afa051c
Promote no-undef to be treated as an error (#669)
gaearon Sep 17, 2016
5f330c8
Add the GitHub issue template (#668)
goshacmd Sep 17, 2016
fc8eb90
Minor tweaks to issue template
gaearon Sep 17, 2016
a77bbdf
Remove caret
gaearon Sep 17, 2016
1828be2
Clarify why we use find-cache-dir
gaearon Sep 17, 2016
a840bcb
Crash the app if it does not find index.html or index.js (#653)
vnctaing Sep 15, 2016
7b62590
Add missing file check to npm run build too
gaearon Sep 17, 2016
72c2bd1
Make --scripts-version work with forked react-scripts (#632)
yesmeck Sep 18, 2016
550c7d8
Tweak scroll sequences
gaearon Sep 18, 2016
1084842
Update webpack-dev-server and add clientLogLevel option
gaearon Sep 18, 2016
9d449f8
Reword comment
gaearon Sep 18, 2016
57ab577
Update postcss-loader for colorful errors
gaearon Sep 18, 2016
981d32f
Update dependencies
gaearon Sep 18, 2016
20d2ddd
Emphasize we recommend Node 6 and npm 3
gaearon Sep 18, 2016
87c57ea
Don't generate absolute paths in Jest config after ejecting
gaearon Sep 18, 2016
d0e6806
Tweak init script output
gaearon Sep 18, 2016
e032018
Provide empty Node mocks for fs, net, tls (#672)
gaearon Sep 18, 2016
6856212
Tweak app name error message
gaearon Sep 18, 2016
d78b29f
Add 0.4.2 changelog (#673)
gaearon Sep 18, 2016
dde4b0b
0.4.2
gaearon Sep 18, 2016
f91257c
0.4.3
gaearon Sep 18, 2016
f3696c7
Add 0.4.3 changelog
gaearon Sep 18, 2016
744fccb
Add test for special scripts versions (#681)
yesmeck Sep 19, 2016
4bc169f
Set up a monorepo with Lerna
fson Sep 18, 2016
6c44d8a
Try to fix e2e
gaearon Sep 19, 2016
952db33
Highlight more prominent alternatives and remove some
gaearon Sep 19, 2016
b1499a0
Fixed broken links in README.md (#683)
tseho Sep 19, 2016
bb2141b
Add a redirect stub because many projects link to old README
gaearon Sep 19, 2016
e96e9ac
Use pre node@4 compatible `path-exists` (#685)
SimenB Sep 19, 2016
898fabc
Create a shareable ESLint configuration package (#689)
fson Sep 21, 2016
97c4cf8
Added instructions for using local images (#589)
iRoachie Sep 21, 2016
1f824c8
Update eslint-plugin-react and enable new rules (#696)
fson Sep 22, 2016
1a9fd51
Bump eslint-config-react-app version to 0.2.0
gaearon Sep 22, 2016
d97d462
Fix the e2e test (#699)
fson Sep 22, 2016
5738078
Extract Babel configuration to babel-preset-react-app (#701)
fson Sep 22, 2016
77ee593
Add support for public/ folder (#703)
gaearon Sep 22, 2016
2f340a8
Attempt to fix the e2e test (#704)
fson Sep 22, 2016
66cc891
Bump babel preset version
gaearon Sep 22, 2016
c1053b8
Fix up eject script
gaearon Sep 22, 2016
a71f633
Eject .babelrc instead of separate configs (#705)
gaearon Sep 22, 2016
190592a
Remove Flow stubs as Flow now supports CSS and resources out of the box
gaearon Sep 23, 2016
177b5ec
openBrowser() causes docker-compose set ups to fail because of spawn …
arekkas Sep 23, 2016
7ad288e
Load environment file in development (#695)
ayrton Sep 23, 2016
74a87a5
Add notes on enabling Travis CI for created repo (#677)
Jiansen Sep 23, 2016
e3d1126
Flow files are removed now
gaearon Sep 23, 2016
9d96d6f
Remove other flow command
gaearon Sep 23, 2016
7a0f3d1
Preserve scripts/test.js after ejecting (#715)
gaearon Sep 23, 2016
71f36b9
Minor tweaks
gaearon Sep 23, 2016
5a01be7
Add READMEs for packages
gaearon Sep 23, 2016
e07e8e6
Add host as adjustable parameter through env variables (#717)
ekaradon Sep 23, 2016
741b5ae
Use bundled local packages in the end-to-end flow (#721)
fson Sep 23, 2016
fa22daf
Add JSX source transform for better warnings (#716)
gaearon Sep 23, 2016
32da910
Extract some utilities into a separate package (#723)
gaearon Sep 23, 2016
567481f
Tweak README
gaearon Sep 23, 2016
49ade22
Bump babel preset version
gaearon Sep 23, 2016
f6a0fbf
Bump eslint preset version
gaearon Sep 23, 2016
9b978be
Bump create-react-app version
gaearon Sep 23, 2016
eaed104
Don't hardcode react-scripts package name (#728)
gaearon Sep 23, 2016
598c8ee
Explain how to use #703
gaearon Sep 23, 2016
62df2b7
Fix README links
gaearon Sep 23, 2016
79d594f
Add 0.5.0 changelog
gaearon Sep 23, 2016
3a430e7
Fix eject
gaearon Sep 23, 2016
b8444c0
0.5.0
gaearon Sep 23, 2016
4733bab
Publish
gaearon Sep 23, 2016
40085ab
simplify `protocol === "https" ? true : false` to `protocol === "http…
kasperpeulen Sep 23, 2016
693e383
Fix InterpolateHtmlPlugin only replacing the first occurrence (#731)
fson Sep 23, 2016
0945f30
Bump lerna
gaearon Sep 23, 2016
7af06bf
Add 0.5.1 to changelog
gaearon Sep 23, 2016
de4649c
Remove unintentionally committed bundledDependencies
gaearon Sep 23, 2016
b66a65b
Bump lerna
gaearon Sep 23, 2016
d113ead
0.5.1
gaearon Sep 23, 2016
65a146e
Docs: Fix link to recent version of this guide (#732)
forresst Sep 24, 2016
7441d62
Fix README edit link (#739)
fson Sep 24, 2016
eae3245
Add syntax error overlay in development (#744)
gaearon Sep 25, 2016
8f499ec
Add fixed versions of ESLint plugins to the guide
gaearon Sep 25, 2016
54b48a0
Fix error overlay in Firefox (#749)
gaearon Sep 25, 2016
658d847
Add an unobtrusive log when server disconnects
gaearon Sep 25, 2016
4e9c391
Add 0.6.0 changelog
gaearon Sep 25, 2016
73e9cfe
0.6.0
gaearon Sep 25, 2016
aad185b
Add an extra section about updating to README
gaearon Sep 25, 2016
d63077e
Mention the npm bug in migration instructions
gaearon Sep 25, 2016
0f64ef6
Forked react-scripts should retain the binary name (#754)
shubheksha Sep 25, 2016
e8507b2
Bump recursive-readdir (#756)
fson Sep 25, 2016
fb8330a
Remove the `.` at the end of the init message (#760)
vjeux Sep 26, 2016
b81b035
Fix the right and bottom padding of the error overlay (#758)
fson Sep 26, 2016
0349d0c
added link to better visualizing tool (#764)
da-vaibhav Sep 26, 2016
fadda2f
Moved Babel and ESLint config to package.json after ejecting (#773)
montogeek Sep 27, 2016
02275a8
Add 0.6.1 changelog
gaearon Sep 27, 2016
ffb0ad3
Publish
gaearon Sep 27, 2016
d5ff014
Fix the doc
gaearon Sep 28, 2016
0c8a3bf
Relaxed eslint rule no-unused-expressions (#724)
cannona Sep 30, 2016
bd17237
Fix usage example to match [email protected] API
gaearon Sep 30, 2016
fe65fcc
Add Netlify to deploy instructions
biilmann Aug 6, 2016
5c3696e
Typo fix in webpack.config.dev.js comments (#777)
sebastiandedeyne Sep 30, 2016
3c4a571
Define process.env as object (#807)
Sep 30, 2016
ed2f523
Beaufity output of eject.js script (#769)
azakordonets Sep 30, 2016
28ce284
Fix some typos (#809)
existentialism Oct 1, 2016
f6f4523
Fix typo (#810)
vadi2 Oct 1, 2016
7352237
Add explicit linebreaks (#813)
gaearon Oct 1, 2016
03a3301
Fix typos on ISSUE_TEMPLATE.md (#817)
imagentleman Oct 1, 2016
a7b9b13
docs(readme): peer dependencies applied (#818)
JisuPark Oct 2, 2016
2e62323
Fix script name to open chrome (#831)
unixdev Oct 3, 2016
bb69f14
Promote "React must be in scope" to be an error (#822)
gaearon Oct 3, 2016
91c0731
Tweak eject output
gaearon Oct 3, 2016
b24a89a
Make webpackHotDevClient support webpack 2 too (#840)
michalkvasnicak Oct 4, 2016
a73b928
Update instructions on publishing to GitHub pages (#841)
Janpot Oct 4, 2016
345b38c
Tweak readme
fson Oct 4, 2016
0c59b59
Spell check (#845)
pastorsj Oct 4, 2016
9732878
load setupTests file at setupTestFramework stage (#846)
just-boris Oct 5, 2016
b6673c3
Correct a comment mistype in webpack production config (#855)
MunGell Oct 6, 2016
f9bf8b3
Bump babel-plugin-transform-regenerator (#864)
akofman Oct 7, 2016
ef38d79
#765 - Work on removing publish feature flags. Removing copying files…
hycner Oct 7, 2016
d7bdab6
Clean up e2e script (#867)
gaearon Oct 7, 2016
8e99095
Exit production build if any errors are in build stats (#859)
pdillon Oct 7, 2016
acd5518
Disable ES2015 transforms based on node version using babel-preset-en…
shubheksha Oct 11, 2016
31a96f4
Upgrade to Jest 16 (#858)
chase Oct 11, 2016
4f9a803
Support passing scoped package names to --scripts-version arg (#826)
pdillon Oct 11, 2016
31d2b99
Dispose error overlay when linting errors have been corrected (#856)
jarlef Oct 11, 2016
cf4b5e3
Create asset filenames mapping on the build output (#891)
lukyth Oct 11, 2016
819f97a
Fix using pre-release tags with a tarball url in `--scripts-version` …
jihchi Oct 12, 2016
356a1c1
Add 0.7.0 changelog
fson Oct 12, 2016
4bec7f9
Update the snapshot update instructions for 0.7.0
fson Oct 12, 2016
91a8e40
Added note about env server restart (#903)
mxkxf Oct 14, 2016
43d9353
Temporarily remove 0.7.0 changelog as it's not out yet
gaearon Oct 14, 2016
8c3e0f7
Fix Travis CI config in template README.md (#910)
scholtzm Oct 17, 2016
d9d93d2
Enable babel parameters/destructuring for all versions of Node (#927)
JeffreyATW Oct 18, 2016
494914e
PostCSS should run on @import statements. (#929)
nhunzaker Oct 19, 2016
ca4edba
Update dependencies (#945)
fson Oct 22, 2016
226b360
Forbid Webpack loader syntax in imports (#803)
fson Oct 22, 2016
b1430db
Revert "Temporarily remove 0.7.0 changelog as it's not out yet"
fson Oct 22, 2016
0491d3e
Update changelog for 0.7.0
fson Oct 22, 2016
4ecabcc
Update eslint-config-react-app version in the guide
fson Oct 22, 2016
4d0a02c
Publish
fson Oct 22, 2016
c93385f
Update CLI version in changelog
fson Oct 22, 2016
db5687b
Fix an attribution link in 0.7.0 changelog
fson Oct 23, 2016
2aefcef
Encourage people to try recent npm
gaearon Oct 24, 2016
11ba47b
Revert "fast forward to @b284377"
feiqitian Oct 25, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "react-app"
}
7 changes: 0 additions & 7 deletions .eslintrc.js

This file was deleted.

2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ build
*.tgz
my-app*
template/src/__tests__/__snapshots__/
lerna-debug.log
npm-debug.log
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ node_js:
- 6
cache:
directories:
- global-cli/node_modules
- node_modules
- packages/create-react-app/node_modules
- packages/react-scripts/node_modules
script: tasks/e2e.sh
381 changes: 381 additions & 0 deletions CHANGELOG.md

Large diffs are not rendered by default.

59 changes: 47 additions & 12 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,53 @@
# Contributing to `create-react-app`
# Contributing to Create React App

♥ `create-react-app` and want to get involved? Thanks! There are plenty of ways you can help!
Loving Create React App and want to get involved? Thanks! There are plenty of ways you can help.

Please take a moment to review this document in order to make the contribution process easy and effective for everyone involved.

Following these guidelines helps to communicate that you respect the time of the developers managing and developing this open source project. In return, they should reciprocate that respect in addressing your issue or assessing patches and features.

## Core ideas
## Core Ideas

We do not want any flags or configuration, that would defeat the purpose of this tool. We want to find good defaults and actively find ways to improve the developer experience.
As much as possible, we try to avoid adding configuration and flags. The purpose of this tool is to provide the best experience for people getting started with React, and this will always be our first priority. This means that sometimes we [sacrifice additional functionality](https://gettingreal.37signals.com/ch05_Half_Not_Half_Assed.php) (such as server rendering) because it is too hard to solve it in a way that wouldn’t require any configuration.

We try not to make any controversial choices. If the community is split between different tools, we won't just pick the least controversial or most popular, the tool itself should be agnostic between them.
We prefer **convention, heuristics, or interactivity** over configuration.
Here’s a few examples of them in action.

*These ideas are subject to change at any time*
### Convention

Instead of letting the user specify the entry filename, we always assume it to be `src/index.js`. Rather than letting the user specify the output bundle name, we generate it, but make sure to include the content hash in it. Whenever possible, we want to leverage convention to make good choices for the user, especially in cases where it’s easy to misconfigure something.

### Heuristics

Normally, `npm start` runs on port `3000`, and this is not explicitly configurable. However some environments like cloud IDEs want the programs to run on a specific port to serve their output. We want to play well with different environments, so Create React App reads `PORT` environment variable and prefers it when it is specified. The trick is that we know cloud IDEs already specify it automatically so there is no need for the user to do anything. Create React App relies on heuristics to do the right thing depending on environment.

Another example of this is how `npm test` normally launches the watcher, but if the `CI` environment variable is set, it will run tests once. We know that popular CI environments set this variable so the user doesn’t need to do anything. It just works.

### Interactivity

We prefer to add interactivity to the command line interface rather than add configuration flags. For example, `npm start` will attempt to run with port `3000` by default but it may be busy. Many other tools just fail in this case and ask that you pass a different port, but Create React App will display a prompt asking if you’d like to run the app on the next available port.

Another example of interactivity is `npm test` watcher interface. Instead of asking people to pass command line flags for switching between test runner modes or search patterns, we print a hint with keys that you can press during the test session to instruct watcher what to do. Jest supports both flags and interactive CLI but Create React App prefers long-running sessions to keep user immersed in the flow over short-running sessions with different flags.

### Breaking the Rules

No rules are perfect. Sometimes we may introduce flags or configuration if we believe the value is high enough to justify the mental cost. For example, we know that apps may be hosted paths different from the root, and we need to support this use case. However we still try to fall back to heuristics when possible. In this example, we ask that you specify `homepage` in `package.json`, and infer the correct path based on it. We also nudge the user to fill out the `homepage` after the build so the user becomes aware that the feature exists.

## Submitting a Pull Request

Good pull requests - patches, improvements, new features - are a fantastic help. They should remain focused in scope and avoid containing unrelated commits.
Good pull requests, such as patches, improvements, and new features, are a fantastic help. They should remain focused in scope and avoid containing unrelated commits.

Please **ask first** if somebody else is already working on this or the core developers think your feature is in-scope for `create-react-app`. Generally always have a related issue with discussions for whatever you are including.
Please **ask first** if somebody else is already working on this or the core developers think your feature is in-scope for Create React App. Generally always have a related issue with discussions for whatever you are including.

Please also provide a **test plan**, i.e. specify how you verified what you added works.
Please also provide a **test plan**, i.e. specify how you verified that your addition works.

## Setting up a local copy of the repository
## Setting Up a Local Copy

1. Clone the repo with `git clone https://github.com/facebookincubator/create-react-app`

2. Run `npm install` in the root `create-react-app` folder **and** the `create-react-app/global-cli` folder
2. Run `npm install` in the root `create-react-app` folder.

Once it is done, you can modify any file locally and run `npm start` or `npm run build` just like in a generated project.
Once it is done, you can modify any file locally and run `npm start`, `npm test` or `npm run build` just like in a generated project.

If you want to try out the end-to-end flow with the global CLI, you can do this too:

Expand All @@ -39,4 +58,20 @@ cd my-app

and then run `npm start` or `npm run build`.

## Cutting a Release

1. Tag all merged PRs that go into the release with the relevant milestone.
2. Close the milestone.
3. In most releases, only `react-scripts` needs to be released. If you don’t have any changes to the `packages/create-react-app` folder, you don’t need to bump its version or publish it (the publish script will publish only changed packages).
4. Note that files in `packages/create-react-app` should be modified with extreme caution. Since it’s a global CLI, any version of `create-react-app` (global CLI) including very old ones should work with the latest version of `react-scripts`.
5. Add an entry to `CHANGELOG.md` detailing what has changed with links to PRs and their authors. Use previous entries for inspiration. Group changes to `react-scripts` and `create-react-app` separately in the notes, for example like in `0.2.0` release notes.
6. Make sure to include “Migrating from ...” instructions for the previous release. Often you can copy and paste them.
7. After merging the changelog update, create a GitHub Release with the same text. See previous Releases for inspiration.
8. **Do not run `npm publish`. Instead, run `npm run publish`.**
9. Wait for a long time, and it will get published. Don’t worry that it’s stuck. It will bundle dependencies into a single tarball before publishing for faster installs. In the end the publish script will prompt for versions before publishing the packages.

Make sure to test the released version! If you want to be extra careful, you can publish a prerelease by running `npm run publish -- --tag next` instead of `npm run publish`.

------------

*Many thanks to [h5bp](https://github.com/h5bp/html5-boilerplate/blob/master/CONTRIBUTING.md) for the inspiration with this contributing guide*
39 changes: 39 additions & 0 deletions ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
If you are reporting a bug, please fill in below. Otherwise feel free to remove this template entirely.

### Description

What are you reporting?

### Expected behavior

Tell us what you think should happen.

### Actual behavior

Tell us what actually happens.

### Environment

Run these commands in the project folder and fill in their results:

1. `npm ls react-scripts` (if you haven’t ejected):
2. `node -v`:
3. `npm -v`:

Then, specify:

1. Operating system:
2. Browser and version:

### Reproducible Demo

Please take the time to create a new app that reproduces the issue.

Alternatively, you could copy your app that experiences the problem and start removing things until you’re left with the minimal reproducible demo.

(Accidentally, you might get to the root of your problem during that process.)

Push to GitHub and paste the link here.

By doing this, you're helping the Create React App contributors a big time!
Demonstrable issues gets fixed faster.
77 changes: 60 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Create React App
# Create React App [![Build Status](https://travis-ci.org/facebookincubator/create-react-app.svg?branch=master)](https://travis-ci.org/facebookincubator/create-react-app)

Create React apps with no build configuration.

* [Getting Started](#getting-started) – How to create a new app.
* [User Guide](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md) – How to develop apps bootstrapped with Create React App.

## tl;dr

```sh
Expand All @@ -28,7 +31,9 @@ Install it once globally:
npm install -g create-react-app
```

**You’ll need to have Node >= 4 on your machine**. We recommend to use Node >= 6 and npm >= 3 for faster installation speed and better disk usage. You can use [nvm](https://github.com/creationix/nvm#usage) to easily switch Node versions between different projects.
**You’ll need to have Node >= 4 on your machine**.

**We strongly recommend to use Node >= 6 and npm >= 3 for faster installation speed and better disk usage.** You can use [nvm](https://github.com/creationix/nvm#usage) to easily switch Node versions between different projects.

**This tool doesn’t assume a Node backend**. The Node installation is only required for the build tools that rely on it locally, such as Webpack and Babel.

Expand All @@ -47,14 +52,16 @@ Inside that directory, it will generate the initial project structure and instal
```
my-app/
README.md
index.html
favicon.ico
node_modules/
package.json
.gitignore
public/
favicon.ico
index.html
src/
App.css
App.js
App.test.js
index.css
index.js
logo.svg
Expand All @@ -73,6 +80,13 @@ You will see the build errors and lint warnings in the console.

<img src='https://camo.githubusercontent.com/41678b3254cf583d3186c365528553c7ada53c6e/687474703a2f2f692e696d6775722e636f6d2f466e4c566677362e706e67' width='600' alt='Build errors'>

### `npm test`

Runs the test watcher in an interactive mode.
By default, runs tests related to files changes since the last commit.

[Read more about testing.](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#running-tests)

### `npm run build`

Builds the app for production to the `build` folder.<br>
Expand All @@ -81,10 +95,36 @@ It correctly bundles React in production mode and optimizes the build for the be
The build is minified and the filenames include the hashes.<br>
Your app is ready to be deployed!

## How Do I…?

The generated project will include a guide in its README.<br>
You can also read its latest version [here](https://github.com/facebookincubator/create-react-app/blob/master/template/README.md).
## User Guide

The [User Guide](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md) includes information on different topics, such as:

- [Updating to New Releases](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#updating-to-new-releases)
- [Folder Structure](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#folder-structure)
- [Available Scripts](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#available-scripts)
- [Displaying Lint Output in the Editor](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#displaying-lint-output-in-the-editor)
- [Installing a Dependency](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#installing-a-dependency)
- [Importing a Component](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#importing-a-component)
- [Adding a Stylesheet](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#adding-a-stylesheet)
- [Post-Processing CSS](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#post-processing-css)
- [Adding Images and Fonts](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#adding-images-and-fonts)
- [Using the `public` Folder](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#using-the-public-folder)
- [Adding Bootstrap](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#adding-bootstrap)
- [Adding Flow](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#adding-flow)
- [Adding Custom Environment Variables](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#adding-custom-environment-variables)
- [Can I Use Decorators?](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#can-i-use-decorators)
- [Integrating with a Node Backend](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#integrating-with-a-node-backend)
- [Proxying API Requests in Development](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#proxying-api-requests-in-development)
- [Using HTTPS in Development](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#using-https-in-development)
- [Generating Dynamic `<meta>` Tags on the Server](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#generating-dynamic-meta-tags-on-the-server)
- [Running Tests](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#running-tests)
- [Deployment](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#deployment)

A copy of the user guide will be created as `README.md` in your project folder.

## How to Update to New Versions?

Please refer to the [User Guide](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#updating-to-new-releases) for this and other information.

## Philosophy

Expand All @@ -105,7 +145,7 @@ You can also read its latest version [here](https://github.com/facebookincubator
* Autoprefixed CSS, so you don’t need `-webkit` or other prefixes.
* A `build` script to bundle JS, CSS, and images for production, with sourcemaps.

**The feature set is intentionally limited**. It doesn’t support advanced features such as server rendering or CSS modules. Currently, it doesn’t support testing either. The tool is also **non-configurable** because it is hard to provide a cohesive experience and easy updates across a set of tools when the user can tweak anything.
**The feature set is intentionally limited**. It doesn’t support advanced features such as server rendering or CSS modules. The tool is also **non-configurable** because it is hard to provide a cohesive experience and easy updates across a set of tools when the user can tweak anything.

**You don’t have to use this.** Historically it has been easy to [gradually adopt](https://www.youtube.com/watch?v=BF58ZJ1ZQxY) React. However many people create new single-page React apps from scratch every day. We’ve heard [loud](https://medium.com/@ericclemmons/javascript-fatigue-48d4011b6fc4) and [clear](https://twitter.com/thomasfuchs/status/708675139253174273) that this process can be error-prone and tedious, especially if this is your first JavaScript build stack. This project is an attempt to figure out a good way to start developing React apps.

Expand All @@ -124,7 +164,6 @@ You don’t have to ever use `eject`. The curated feature set is suitable for sm
Some features are currently **not supported**:

* Server rendering.
* Testing.
* Some experimental syntax extensions (e.g. decorators).
* CSS Modules.
* LESS or Sass.
Expand All @@ -141,7 +180,8 @@ Currently it is a thin layer on top of many amazing community projects, such as:
* [Babel](http://babeljs.io/) with ES6 and extensions used by Facebook (JSX, [object spread](https://github.com/sebmarkbage/ecmascript-rest-spread/commits/master), [class properties](https://github.com/jeffmo/es-class-public-fields))
* [Autoprefixer](https://github.com/postcss/autoprefixer)
* [ESLint](http://eslint.org/)
* and more.
* [Jest](http://facebook.github.io/jest)
* and others.

All of them are transitive dependencies of the provided npm package.

Expand All @@ -159,21 +199,24 @@ We are grateful to the authors of existing related projects for their ideas and

## Alternatives

If you don’t agree with the choices made in this project, you might want to explore alternatives with different tradeoffs:
If you don’t agree with the choices made in this project, you might want to explore alternatives with different tradeoffs.
Some of the more popular and actively maintained ones are:

* [insin/nwb](https://github.com/insin/nwb)
* [mozilla/neo](https://github.com/mozilla/neo)
* [NYTimes/kyt](https://github.com/NYTimes/kyt)

Notable alternatives also include:

* [enclave](https://github.com/eanplatter/enclave)
* [nwb](https://github.com/insin/nwb)
* [motion](https://github.com/motion/motion)
* [rackt-cli](https://github.com/mzabriskie/rackt-cli)
* [budō](https://github.com/mattdesl/budo)
* [rwb](https://github.com/petehunt/rwb)
* [quik](https://github.com/satya164/quik)
* [sagui](https://github.com/saguijs/sagui)
* [roc](https://github.com/rocjs/roc)
* [aik](https://github.com/d4rkr00t/aik)
* [react-app](https://github.com/kriasoft/react-app)
* [dev-toolkit](https://github.com/stoikerty/dev-toolkit)
* [mozilla-neo](https://github.com/mozilla/neo)
* [tarec](https://github.com/geowarin/tarec)

You can also use module bundlers like [webpack](http://webpack.github.io) and [Browserify](http://browserify.org/) directly.<br>
React documentation includes [a walkthrough](https://facebook.github.io/react/docs/package-management.html) on this topic.
Loading