@oc-digital/data-snippets
v6.13.0
Published
A shared graphql snippets package
Keywords
Readme
OC-Digital graphql snippets library
Local development usage
For use during early testing on your machine:
- In the downstream app run
npm install ../data-snippets(use the path to this repo) - Start your downstream app in watch mode (for Partners this is just npm start)
- In here, run
npm run build(you'll need to re-run this after making changes) - It will use the latest locally-built version in the downstream app
Note Don't commit the
package.jsonchange to github! It won't work on the code build system.
Beta usage
When you've tested it locally and its working, do a beta deploy as follows:
- check the package version in
package.jsonand increment it according to semantic versioning (details below) - run
npm version 2.0.7-beta.0using the incremented package version followed by-beta.0for testing- increment it to
2.0.7-beta.1for further beta tests
- increment it to
- run
npm publish --tag betato publish to npm (don't forget the--tag beta!) - in the downstream app run
npm install @oc-digital/[email protected]replacing with your version number
Publishing a new version
- Update the version in
package.json - Create and push a git tag:
git tag v1.2.3 git push origin v1.2.3
The package will be automatically published to npm via GitHub Actions.
Versioning
This package uses semantic versioning.
To summarise the above link:
- The version is in the format MAJOR.MINOR.PATCH.
- If you make a breaking change (eg you remove a snippet or fields from a snippet), increment the MAJOR version.
- If you add a new snippet, increment the MINOR version.
- If you add fields to an existing snippet, increment the PATCH version.
