- Fork the repo
- Clone the forked repo
$ git clone git@github.com:YOUR_USERNAME/react-http-fetch.git
- Install dependencies
$ cd react-http-fetch
$ yarn
- Link the local package:
$ yarn link
- Create a sandbox react app:
$ cd ..
$ create-react-app react-http-fetch-sandbox
$ cd react-http-fetch-sandbox
$ yarn
- Link the local library to the sanbox:
$ yarn link react-http-fetch
- Link react and react-dom:
$ yarn --cwd node_modules/react link
$ yarn --cwd node_modules/react-dom link
- Link react peer deps to local library:
$ cd ../react-http-fetch
$ yarn link react
$ yarn link react-dom
- Start library build in watch mode:
$ yarn build:watch
In a second terminal window
, start React app:
$ cd ../react-http-fetch-sandbox
$ yarn start
That's it!
Now you can use the local library in your local sandbox. Any change to library source code should cause it to recompile and the sandbox app to refresh.
Bu sure to cover any changes to the source code by integrating the tests suite.
Push your changes against your forked repo and make a PR against nebarf/react-http-fetch:main
.