Skip to content

How to update and publish react scripts

Ivan edited this page Feb 14, 2019 · 3 revisions

Most of the times you just want to stay in sync with official CRA repo, or to tweak some things.
Bellow you find some steps to help you with this process.

Prerequisites

  1. Access to https://github.com/winify-ag/create-react-app
  2. Access to https://www.npmjs.com/org/winify/react-scripts
  3. Clone https://github.com/winify-ag/create-react-app
    git clone git@github.com:winify-ag/create-react-app.git
  4. Add official repo as upstream
    git remote add upstream git@github.com:facebook/create-react-app.git

Steps

  1. [Optional] Make desired changes and commit them
  2. Apply updates from official repo
    • git fetch upstream master
    • git rebase upstream/master
  3. Update package.json name and version.
    As a convention keep version in sync with official release if possible.
    Also try put this changes in previous commit(keep it simple)
  4. Publish it
    • cd {CRA}/packages/react-scripts
    • npm publish --access public
Clone this wiki locally