please use npm v7.x
or newer version, because we need the npm's workspaces feature.
# setup the dev environment
npm i
# build all packages
npm run build
Every time you fix a bug or introduce a new feature to @cocos/scripting
, please remember considering to add your unit test into test
folder.
# run test
npm test
# update the snapshot
npm test -- -u
We use changesets to manage all the changelog.
Every time you make a change in the repo, please generate a changeset in the folder .changeset
, this file should be also commit to the repo.
# generate changelog
npm run change
Remember to update the public API every time you change the interface.
# generate API report in '.api' directory
npm run api
You can generate API document in this way:
# use typedoc to generate API document
npm run doc
Please version the package before you publish.
# this command would consume all the changesets in `.changeset` folder.
npm run version
# this command won't consume any of the changesets.
npm run version-alpha
Create a release version on Github, ci runner will generate a npm package and commit to the offical npm registry for us.
npm run deploy