6.2.2 • Published 12 days ago

@govuk-one-login/di-ipv-cri-common-express v6.2.2

Weekly downloads
-
License
MIT
Repository
github
Last release
12 days ago

ipv-cri-common-express

GitHub Action: Scan repository Coverage

di-ipv-cri-common-express contains Express libraries and utilities for use building GOV.UK One Login Credential Issuers

It provides functionality for use with an Express webserver, GOV.UK Design System and the HMPO Components library

This package contains:

  • assets
    • JavaScript used for progressive enhancement
  • components
  • lib
    • Express middleware
  • routes
    • Express router to handle common OAuth functionality
  • scripts
    • checkTranslations script used to ensure localisation files are kept synchronised

GA4 and the Crown Logo

The implementation of GA4 and the Crown Logo update are contained across multiple versions of common-express in various stages. See below for details:

5.1.0

  • Contains the flag to activate the new crown logo set to true ready for go-live of that feature

Installation

Clone this repository and then run

npm install

Development

Tests

mocha is used as the testing framework.

To run the tests:

npm run test

Linting and code formatting

Linting and code formatting are applied using a combination of prettier, eslint.

These can be run manually using:

npm run lint

Commit Hooks

Linting and code formatting is enforced on commit using pre-commit.

Pre-commit hooks can be run manually using:

pre-commit run --all-files

Note: Husky was previously used, and will need to be de-configured using git config --unset-all core.hooksPath and re-configured using pre-commit install

Release Procedure

Releases are automatically published to npm at @govuk-one-login/di-ipv-cri-common-express using a GitHub action upon creation of an appropriate Git tag.

The previous usage of "govuk-one-login/ipv-cri-common-express.git#v4.0.0" should not be used as this has no support for package building, which will be a requirement with future improemetns

In order to prepare a new release

  1. git checkout a fresh copy of the main branch
  2. create a separate branch for the version to be updated to (e.g. chore/release/v1.2.3
  3. Run npm version VERSION --no-git-tag-version, changing VERSION to be major, minor or patch as required
    • Once this has been run, the package.json and package-lock.json files will be updated with the new version.
  4. Create a PR for this change, and get this approved and merged
  5. Once this has been done, a release can be created using GitHub by accessing the releases section.
  6. Choose a new tag matching your version number, prefixed with v to avoid Git reference collisions, e.g. v1.2.3
  7. Click on the "Generate release notes" button to automatically pull in commit messages for the release notes.

Code Owners

This repo has a CODEOWNERS file in the root and is configured to require PRs to reviewed by Code Owners.

Peer Dependencies

This node package includes the initialisation script from the GDS Analytics package (https://www.npmjs.com/package/@govuk-one-login/frontend-analytics).

6.2.2

12 days ago

6.2.1

25 days ago

6.2.0

1 month ago

5.1.0

2 months ago

6.1.0

2 months ago

6.0.0

2 months ago

5.0.0

3 months ago

4.0.0-0

6 months ago

3.4.0

6 months ago

3.3.0

6 months ago

3.2.0

6 months ago

3.1.0

7 months ago

3.0.0

7 months ago

3.0.0-rc.0

7 months ago