An app to help come up with names. Names will compete against each other resulting in a ranked set of names.
To learn more about the process and how to contribute, see the Contribution Guide
In the project directory, you can run:
Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.
The page will reload if you make edits.
You will also see any lint errors in the console.
Launches the test runner in the interactive watch mode.
See the section about running tests for more information.
Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes.
Your app is ready to be deployed!
See the section about deployment for more information.
Note: this is a one-way operation. Once you eject, you can’t go back!
If you aren’t satisfied with the build tool and configuration choices, you can eject at any time. This command will remove the single build dependency from your project.
Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except eject will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.
You don’t have to ever use eject. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.
The two main folder structures within the project are /src and /server.
The src folder contains the front-end source code. It has the below structure
src/
__mocks__/
__tests__/
actions/
assets/
components/
containers/
reducers/
store/
utils/
Contains mock data or implementations to be used within tests
Contains the unit tests for the application. All files should end with the extension .test.js. The tests folder structure follows the same format as the src folder which can look something like:
__tests__/
components/
ExampleComponent.test.js
containers/
ExampleContainer.test.js
Contains the action types, action creators, and thunk functions for processing actions.
Contains the static assets used within the project such as images
Each component builds it's own folder structure:
components/
ExampleComponent/
index.js
ExampleComponent.jsx
Contains presentational React components. These components should not have local state and are not directly connected to the redux store. The state and functional logic can be found in an associated container which allows us to decouple our logic from our views.
// ExampleComponent.jsx
import React, { PureComponent } from 'react';
class ExampleComponent extends PureComponent{
render(){
return (
<p>Example</p>
);
}
}
export default ExampleComponent;
Each container builds it's own folder structure:
containers/
ExampleContainer/
index.js
ExampleContainer.jsx
Contains stateful React components. These components house the functional logic that is tied to a presentation component. This can include local state and connecting to the redux store.
// ExampleContainer.jsx
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { ExampleComponent } from '../../components/ExampleComponent';
export class ExampleContainer extends Component{
constructor(props){
super(props);
this.state = {
example: 'exampleState',
};
}
render(){
return (
<ExampleComponent
example={this.state.example}
connectedExample={this.props.connectedProp}
callback={this.props.dispatcherProp}
/>
);
}
}
export mapStateToProps = ....
export mapDispatchToProps = ....
export default connect(mapStateToProps, mapDispatchToProps)(ExampleContainer);
Redux reducer logic that processes actions to change the store state. The index file returns the combined reducers.
Holds folders for enhancers and middleware to use within the redux store. A different file for configuring a development store and a production store are also within this folder. The index.js will configure the correct store based on the environment it is being built for.
Holds the common utility functions and constants to be used across the entire app.
The front-end tests are processed using Jest.
The files are pre-processed using prettier during a commit to ensure a consistent coding style. I also use eslint with the google linter as a base. Special rules can be found within the .eslintrc file.
You can learn more in the Create React App documentation.
To learn React, check out the React documentation.
This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting
This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size
This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app
This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration
This section has moved here: https://facebook.github.io/create-react-app/docs/deployment