This Turborepo includes the following packages/apps:
customer
: a Next.js app, an open source Monerium client@monerium/sdk
: an SDK for interacting with the Monerium API@monerium/sdk-react-provider
: a React provider for the Monerium SDK@repo/ui
: a sharable stub React component library@repo/eslint-config
:eslint
configurations (includeseslint-config-next
andeslint-config-prettier
)@repo/postcss-config
:postcss
configurations@repo/stylelint-config
:stylelint
configurations@repo/typescript-config
:tsconfig.json
's used throughout the monorepo
- TurboRepo for monorepo management
- TypeScript for static type checking
- ESLint for code linting
- Prettier for code formatting
- PostCSS for CSS processing
- Stylelint for CSS linting
- Jest for testing
- Commitlint for commit message linting
- Husky for Git hooks
- Lint-Staged for running linters on staged files
- Release Please for automated releases
To build all apps and packages, run the following command:
cd js-monorepo
pnpm build
To develop all apps and packages, run the following command:
cd js-monorepo
pnpm dev
Note: use pnpm dev --log-order stream
for a more traditional log output.
We use release-please, for automated releases. The configuration file is located at release-please-config.json
, and the manifest file is at .release-please-manifest.json
. In general, you don't need to manually update the manifest file because the release-please action automatically updates it.
If you need to adjust a package version, you can update the release-please-config.json
file with "release-as": "0.0.1"
for that package. Just remember to remove it after the release.
To trigger a release, you merge a PR into the main branch. The release process will create a new release branch and a PR. When you merge this PR into the main branch, a release will be created.
The pipeline will automatically publish the following packages if there are changes when a release is created:
@monerium/sdk
at 'packages/sdk'@monerium/sdk-react-provider
at 'packages/sdk-react-provider'- TBD:
@repo/ui
at 'packages/ui'
Release please - Github action
Release please - Config file options
Turborepo can use a technique known as Remote Caching to share cache artifacts across machines, enabling you to share build caches with your team and CI/CD pipelines.
By default, Turborepo will cache locally. To enable Remote Caching you will need an account with Vercel. If you don't have an account you can create one, then enter the following commands:
cd my-turborepo
npx turbo login
This will authenticate the Turborepo CLI with your Vercel account.
Next, you can link your Turborepo to your Remote Cache by running the following command from the root of your Turborepo:
npx turbo link
Learn more about the power of Turborepo:
Verify that the package version is not set to a specific version with "release-as"
in the release-please-config.json
file. If it is, remove it and merge the PR again.