Ripple Design System

Access to Github Packages

How to access and use repos hosted on Github Packages.

NPM allows the use of multiple repo hosts, as long as they can be identified by namespace.

Ripple 2 is hosted publicly on Github Packages (ghcr) under the @dpc/sdp namespace, so a few steps need to be followed access these packages, while also co-existing with the npm ecosystem.

First, create a Personal Access Token on Github:

  1. Visit and select Generate new token > Generate new token (classic)
Screenshot of a clicked button (title Generate new token) that has opened a drop-down menu with two options: fine-grained and classic
  1. Fill in the Note and choose an Expiration - the 30 day default is generally fine, you'll receive a reminder to regenerate the token just before expiry
Screenshot of personal access token setup form, with 'Note' filled in as 'public ghcr access' and 'Expiration' set to default of 30 days
  1. Set the scope to only allow read:packages, and Generate token
Screenshot of scope, with only read:packages selected
  1. Store the resulting token somewhere secure, and add it to either a user .npmrc (recommended) or the project-level .npmrc (the url on line 2 below is protocol-less, not a comment):
//<github personal access token>

Propose a change to this page on GitHub.