@bruin-eng/bss-shopping
v1.0.7
Published
BSS shopping/checkout React components (notably `ConfigurationPage`, the dynamic checkout configuration form), published to npm as [`@bruin-eng/bss-shopping`](https://www.npmjs.com/package/@bruin-eng/bss-shopping) and consumed by BruinPortal (`One.MetTe
Downloads
1,138
Keywords
Readme
@bruin-eng/bss-shopping
BSS shopping/checkout React components (notably ConfigurationPage, the dynamic checkout configuration form),
published to npm as @bruin-eng/bss-shopping and consumed by
BruinPortal (One.MetTel.Web/src/react).
Repo topology — read this first
| Repo | Role |
|---|---|
| Bruin/bruin-shopping (this repo) | Package source. Publishes to npm as @bruin-eng/bss-shopping |
| Bruin/Bruin.BssUI | pnpm + turbo monorepo wrapper — includes this repo as the packages/shopping git submodule (plus ui-components, utilities) |
| BruinPortal One.MetTel.Web/src/react | Consumer, via the published npm package |
⚠️ A standalone clone of this repo cannot install or build. The devDependencies reference workspace packages (
@bruin-eng/typescript-config@workspace:*etc.), sopnpm installfails withERR_PNPM_WORKSPACE_PKG_NOT_FOUND. Always work from inside aBruin.BssUImonorepo checkout.
Setup
git clone --recurse-submodules https://git.bruin.com/Bruin/Bruin.BssUI.git
cd Bruin.BssUI
npx -y [email protected] install # the monorepo pins pnpm 9.6.0Feature branches are made inside packages/shopping (it is this repo — full git remote access):
cd packages/shopping
git checkout -b feature/<branch>Build
Build via turbo from the monorepo root so the workspace dependencies (utils, ui-components) build first —
building only this package fails with TS2307: Cannot find module '@bruin-eng/ui-components':
cd Bruin.BssUI
npx -y [email protected] turbo build --filter=@bruin-eng/bss-shopping...Test
cd packages/shopping
npx -y [email protected] vitest runNote: on a fresh clone the ProductSetAssignmentsPanel.test.tsx suite fails on module resolution until the workspace
siblings have been built (run the turbo build above first).
Releasing a new version
Publishing requires an npm account with maintainer rights on the @bruin-eng org (maintainers: bruinny
/ [email protected], plus individual accounts).
Publish auth: npm refuses publishes (E403 Two-factor authentication or granular access token with bypass 2fa
enabled is required) unless the account either has 2FA enabled (then publish with --otp=<code>) or uses a
granular access token with Bypass two-factor authentication checked (npmjs.com → Access Tokens → Generate →
Granular; packages & scopes: @bruin-eng, permissions: Read and write). The bruinny account uses the token route:
npm config set //registry.npmjs.org/:_authToken=npm_**************************** # granular token, bypass-2FA(Token created 2026-07-02 under bruinny; ask [email protected] for the value or generate a fresh one.)
# 1. version bump commit on main (after the feature PR merged)
cd packages/shopping
git checkout main && git pull
# - bump "version" in package.json
# - prepend a CHANGELOG.md entry:
# ## X.Y.Z
# ### Patch Changes
# - <shortsha>: <message>
git add package.json CHANGELOG.md && git commit -m "vX.Y.Z" && git push origin main
# 2. build workspace deps + package (from the monorepo root)
cd ../..
npx -y [email protected] turbo build --filter=@bruin-eng/bss-shopping...
# 3. publish (from packages/shopping; pnpm's default publish branch is master, hence the flag)
cd packages/shopping
npx -y [email protected] publish --publish-branch main --otp=<2fa-code>
# 4. verify
npm view @bruin-eng/bss-shopping versionUpdating the consumer (BruinPortal)
cd BruinPortal/One.MetTel.Web/src/react
# package.json: "@bruin-eng/bss-shopping": "^X.Y.Z"
pnpm install
FE_REACT_BUILD=forcebuild pnpm build # rebuilds Assets/scripts/react-bundle.*Ship as two PRs per the BruinPortal bundle-separation rule: a source PR (package.json + pnpm-lock.yaml) and a
sibling -bundles PR (react-bundle.js/.map/.css only), merged source-first.
Dev server / Storybook
npx -y [email protected] dev:local # vite dev server
npx -y [email protected] storybook # storybook on :6006