Skip to content

About

Connect support in the Nuxt framework

Topics

Resources

Code of conduct

Contributing

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

License

Connect Nuxt

Connect support in the Nuxt framework

This monorepo contains Nuxt packages for the Connect ecosystem. It is managed using pnpm workspaces and Changesets for versioning and publishing.

Development

Prerequisites

  • Node (version 22.16.x or higher)
  • pnpm (version 10.x or higher)

Setup Create a fork and local copy of this repo. Answer Y to create a local clone.

gh repo fork bcgov/connect-nuxt

Change into the directory and install the packages.

pnpm install

Start the development environment.

# from monorepo root
pnpm --filter package-name dev 
or
# from package root
pnpm run dev

Testing

Run Vitest in watch mode for unit tests

# from monorepo root
pnpm --filter package-name test
or
# from package root
pnpm test

Run Playwright e2e tests Note: Playwright e2e tests are written against the .playground directory to ensure smooth integration of our common features

# from monorepo root
pnpm --filter package-name test:e2e
or
# from package root
pnpm test:e2e

Workspace Structure

This repository is organized into two main directories:

  • packages/: Contains all the reusable, versioned, and publishable libraries. These are the shared building blocks of our system.
    • layers/
      • base: Foundational UI components, theme, and styles.
      • auth: Authentication provider integration, composables, components and accounts.
      • forms: Common form components and validation logic.
      • pay: Components and services related to payments.
  • apps/: Contains deployable applications that consume the packages.

Additional layers can be added under the packages/layers/ directory. Other content should be organized similarly. e.g., Modules should be created under a new packages/modules/ directory.

Pull Request Previews

This repository uses pkg-pr-new for continuous deployment of preview packages. When a pull request is opened that modifies a package, a bot will automatically post a comment with links to install the preview version.

This allows for immediate testing and validation of changes in a live environment without needing to go through the full release process. The comment will also include a link to an interactive StackBlitz environment where the changes can be reviewed.

Note

For subsequent changes pushed to the same pull request, it is required to use the installation link that contains the direct commit hash instead of the PR number (e.g., @a1b2c3d instead of @42). This will ensure you are testing against the absolute latest version and avoid any potential caching issues with the PR number tag.

Versioning & Release Workflow

This monorepo uses Changesets to manage versioning, changelogs, and publishing.

Note

Automated Versioning: Please do not manually update package versions in package.json. This monorepo uses an automated workflow where the Changesets action is responsible for all version bumps, including updating internal dependencies between packages. Please familiarize yourself with the Changesets workflow before contributing.

Adding a Change

When you have made a code change in a PR that should be included in the next release, you must add a changeset.

A detailed step-by-step guide can be found at A Guide to the Changesets Workflow

  1. Run the changeset command (must be done from the repo root):
pnpm changeset
  1. Follow the prompts to select the packages you've changed and the appropriate version bump (patch, minor, or major).
  2. Write a clear summary of your change. Please be descriptive as this summary will be automatically added to the CHANGELOG.md file.
  3. Commit the generated .md file to your branch.

Publishing a Release

The release process is automated by GitHub Actions:

  1. When a PR with one or more changeset files is merged into main, the Changesets action will automatically create a new "Version Packages" pull request.
  2. This new PR will contain all the version bumps and the updated CHANGELOG.md files.
  3. Once the "Version Packages" PR is reviewed and merged, the action will automatically publish the updated packages to the npm registry and create a corresponding GitHub Release.

How to Contribute

If you would like to contribute, please see our CONTRIBUTING guidelines.

Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.

About

Connect support in the Nuxt framework

Topics

Resources

Code of conduct

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages