diff --git a/.eslintrc.js b/.eslintrc.js index d5f44b0b5..3efc19186 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -21,7 +21,7 @@ module.exports = { 'prettier/react', ], - plugins: ['flowtype', 'css-modules', 'prettier'], + plugins: ['flowtype', 'css-modules', 'prettier', 'jest'], globals: { __DEV__: true, @@ -29,6 +29,7 @@ module.exports = { env: { browser: true, + jest: true, }, rules: { @@ -87,6 +88,9 @@ module.exports = { // ESLint plugin for prettier formatting // https://github.com/prettier/eslint-plugin-prettier 'prettier/prettier': 'error', + + 'react/forbid-prop-types': 'off', + 'react/destructuring-assignment': 'off', }, settings: { diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 000000000..ec6d3cdd7 --- /dev/null +++ b/.prettierignore @@ -0,0 +1 @@ +package.json diff --git a/.travis.yml b/.travis.yml index 89f8b988f..6105d4a58 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,9 @@ language: node_js node_js: - 'stable' + - '12' + - '10' - '8' - - '6' env: - CXX=g++-4.8 addons: @@ -11,6 +12,7 @@ addons: - ubuntu-toolchain-r-test packages: - g++-4.8 +cache: yarn script: - yarn lint - yarn test diff --git a/CHANGELOG.md b/CHANGELOG.md index 8cb72826b..d6803765d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ All notable changes to this project will be documented in this file. - Move page / screen components into the `src/routes` folder along with the routing information for them (BREAKING CHANGE). [6553936](https://github.com/kriasoft/react-starter-kit/commit/6553936e693e24a8ac6178f4962af15e0ea87dfd) ### [v0.5.1] + > 2016-03-02 - Remove `Html` React component in favor of compiled Jade templates (`src/views`) (BREAKING CHANGE). [e188388](https://github.com/kriasoft/react-starter-kit/commit/e188388f87069cdc7d501b385d6b0e46c98fed60) @@ -34,6 +35,7 @@ All notable changes to this project will be documented in this file. - Add support for Markdown and HTML for static pages. [#469](https://github.com/kriasoft/react-starter-kit/pull/469), [#477](https://github.com/kriasoft/react-starter-kit/pull/477) ### [v0.5.0] + > 2016-02-27 - Replace RESTful API endpoint (`src/api`) with GraphQL (`src/data`) @@ -54,6 +56,7 @@ All notable changes to this project will be documented in this file. - Add `CHANGELOG.md` file with a list of notable changes to this project ### [v0.4.1] + > 2015-10-04 - Replace React Hot Loader (deprecated) with React Transform diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index aab3a8774..24e66a167 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -33,10 +33,10 @@ files right from GitHub website as described [here](https://help.github.com/arti Before opening an issue, please: -* Check the [Getting Started](https://github.com/kriasoft/react-starter-kit/blob/master/docs/getting-started.md) guide. -* Search the [issue tracker](https://github.com/kriasoft/react-starter-kit/issues) to make sure +- Check the [Getting Started](https://github.com/kriasoft/react-starter-kit/blob/master/docs/getting-started.md) guide. +- Search the [issue tracker](https://github.com/kriasoft/react-starter-kit/issues) to make sure your issue hasn’t already been reported. -* If your issue sounds more like a question, please post it on StackOverflow.com instead with the +- If your issue sounds more like a question, please post it on StackOverflow.com instead with the tag [react-starter-kit](http://stackoverflow.com/questions/tagged/react-starter-kit). ### Pull Requests @@ -44,12 +44,12 @@ Before opening an issue, please: Before you submit a [pull request](https://help.github.com/articles/using-pull-requests/) from your forked repo, check that it meets these guidelines: -* If the pull request adds functionality, the docs should be updated as part of the same PR. -* Create a separate PR for each small feature or bug fix. -* [Squash](http://stackoverflow.com/questions/5189560/squash-my-last-x-commits-together-using-git) +- If the pull request adds functionality, the docs should be updated as part of the same PR. +- Create a separate PR for each small feature or bug fix. +- [Squash](http://stackoverflow.com/questions/5189560/squash-my-last-x-commits-together-using-git) your commits into one for each PR. -* Run `yarn test` to make sure that your code style is OK and there are no any regression bugs. -* When contributing to an opt-in feature, apply the `[feature/...]` tag as a prefix to your PR title +- Run `yarn test` to make sure that your code style is OK and there are no any regression bugs. +- When contributing to an opt-in feature, apply the `[feature/...]` tag as a prefix to your PR title #### Style Guide diff --git a/Dockerfile b/Dockerfile index 5f1f823cc..d8f277125 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:8.10.0-alpine +FROM node:8.16.2-alpine # Set a working directory WORKDIR /usr/src/app @@ -12,7 +12,14 @@ RUN yarn install --production --no-progress # Copy application files COPY ./build . +# Set permissions for "node" user +RUN chown -R node:node /usr/src/app +RUN chmod 755 /usr/src/app + # Run the container under "node" user by default USER node +# Set NODE_ENV env variable to "production" for faster expressjs +ENV NODE_ENV production + CMD [ "node", "server.js" ] diff --git a/README.md b/README.md index 11f6722da..7e33bc201 100644 --- a/README.md +++ b/README.md @@ -21,29 +21,29 @@ and newcomers to the industry. Hiring
- ### Getting Started - * Follow the [getting started guide](./docs/getting-started.md) to download and run the project - ([Node.js](https://nodejs.org/) >= 6.5) - * Check the [code recipes](./docs/recipes) used in this boilerplate, or share yours - +- Follow the [getting started guide](./docs/getting-started.md) to download and run the project + ([Node.js](https://nodejs.org/) >= 8.16.2) +- Check the [code recipes](./docs/recipes) used in this boilerplate, or share yours ### Customization The `master` branch of React Starter Kit doesn't include a Flux implementation or any other -advanced integrations. Nevertheless, we have some integrations available to you in *feature* +advanced integrations. Nevertheless, we have some integrations available to you in _feature_ branches that you can use either as a reference or merge into your project: - * [feature/redux](https://github.com/kriasoft/react-starter-kit/tree/feature/redux) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1084)) - — isomorphic Redux by [Pavel Lang](https://github.com/langpavel) - (see [how to integrate Redux](./docs/recipes/how-to-integrate-redux.md)) (based on `master`) - * [feature/apollo](https://github.com/kriasoft/react-starter-kit/tree/feature/apollo) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1147)) - — isomorphic Apollo Client by [Pavel Lang](https://github.com/langpavel) - (see [Tracking PR #1147](https://github.com/kriasoft/react-starter-kit/pull/1147)) (based on `feature/redux`) - * [feature/react-intl](https://github.com/kriasoft/react-starter-kit/tree/feature/react-intl) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1135)) - — isomorphic Redux and React Intl by [Pavel Lang](https://github.com/langpavel) - (see [how to integrate React Intl](./docs/recipes/how-to-integrate-react-intl.md)) (based on `feature/apollo`) +- [feature/redux](https://github.com/kriasoft/react-starter-kit/tree/feature/redux) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1084)) + — isomorphic Redux by [Pavel Lang](https://github.com/langpavel) + (see [how to integrate Redux](./docs/recipes/how-to-integrate-redux.md)) (based on `master`) +- [feature/apollo](https://github.com/kriasoft/react-starter-kit/tree/feature/apollo) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1147)) + — isomorphic Apollo Client by [Pavel Lang](https://github.com/langpavel) + (see [Tracking PR #1147](https://github.com/kriasoft/react-starter-kit/pull/1147)) (based on `feature/redux`) +- [feature/react-intl](https://github.com/kriasoft/react-starter-kit/tree/feature/react-intl) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1135)) + — isomorphic Redux and React Intl by [Pavel Lang](https://github.com/langpavel) + (see [how to integrate React Intl](./docs/recipes/how-to-integrate-react-intl.md)) (based on `feature/apollo`) +- [feature/apollo-pure](https://github.com/kriasoft/react-starter-kit/tree/feature/apollo-pure) ([PR](https://github.com/kriasoft/react-starter-kit/pull/1666)) + — Apollo devtools and TypeScript integration by [piglovesyou](https://github.com/piglovesyou) (based on `master`) You can see status of most reasonable merge combination as [PRs labeled as `TRACKING`](https://github.com/kriasoft/react-starter-kit/labels/TRACKING) @@ -51,7 +51,6 @@ If you think that any of these features should be on `master`, or vice versa, so removed from the `master` branch, please [let us know](https://gitter.im/kriasoft/react-starter-kit). We love your feedback! - ### Comparison