22
33This repository publishes two public npm packages:
44
5- - ` codex-pets-core `
6- - ` codex-pets -react `
5+ - ` codex-pet-web `
6+ - ` codex-pet-web -react `
77
88## Prerequisites
99
@@ -13,12 +13,11 @@ This repository publishes two public npm packages:
13134 . Confirm package names are available or already owned by the npm account:
1414
1515``` bash
16- npm view codex-pets-core version
17- npm view codex-pets -react version
16+ npm view codex-pet-web version
17+ npm view codex-pet-web -react version
1818```
1919
20- ` codex-pets-react ` already has a historical ` 0.2.0 ` , so this monorepo starts
21- the React package at ` 0.3.0 ` . ` codex-pets-core ` starts at ` 0.1.0 ` .
20+ Both public packages start at ` 0.1.0 ` .
2221
2322Trusted Publishing is preferred over long-lived npm tokens. Configure it on
2423npmjs.com for each published package:
@@ -28,20 +27,14 @@ npmjs.com for each published package:
2827- Workflow filename: ` publish.yml `
2928- Environment name: leave empty
3029
31- At the time this repository was prepared, ` codex-pets-core ` was unclaimed and
32- ` codex-pets-react ` was owned by the ` backnotprop ` npm account. ` codex-pets-core `
33- must be published once before its Trusted Publisher can be configured. Publish
34- it manually after ` npm login ` , then add the same Trusted Publisher settings:
30+ At the time this repository was prepared, both package names were unclaimed.
31+ Each package must be published once before its Trusted Publisher can be
32+ configured. Publish them manually after ` npm login ` , then add the same Trusted
33+ Publisher settings:
3534
3635``` bash
3736npm publish -w packages/core --access public --tag next
38- ```
39-
40- For ` codex-pets-react ` , either configure Trusted Publishing from the
41- ` backnotprop ` npm account or add the publishing npm user as an owner first:
42-
43- ``` bash
44- npm owner add < npm-username> codex-pets-react
37+ npm publish -w packages/react --access public --tag next
4538```
4639
4740Do not create an automation token with 2FA bypass unless Trusted Publishing is
@@ -81,8 +74,8 @@ npm publish -w packages/react --access public --tag next
8174mkdir /tmp/codex-pets-consumer
8275cd /tmp/codex-pets-consumer
8376npm init -y
84- npm install codex-pets-core @next codex-pets -react@next react react-dom
85- node --input-type=module -e " import { CODEX_PET_ATLAS } from 'codex-pets-core '; import { CodexPet } from 'codex-pets -react'; console.log(CODEX_PET_ATLAS.width, typeof CodexPet)"
77+ npm install codex-pet-web @next codex-pet-web -react@next react react-dom
78+ node --input-type=module -e " import { CODEX_PET_ATLAS } from 'codex-pet-web '; import { CodexPet } from 'codex-pet-web -react'; console.log(CODEX_PET_ATLAS.width, typeof CodexPet)"
8679```
8780
8881Expected output includes:
@@ -105,7 +98,7 @@ npm publish -w packages/react --access public --tag latest
10598
10699## Versioning Notes
107100
108- - Keep ` codex-pets -react ` dependent on the matching compatible
109- ` codex-pets-core ` range.
101+ - Keep ` codex-pet-web -react ` dependent on the matching compatible
102+ ` codex-pet-web ` range.
110103- Update ` CHANGELOG.md ` before each release.
111104- Run ` npm run pack:dry ` and inspect tarball contents before publishing.
0 commit comments