Install directly in browsers using a free and highly available CDN:
Certain components of SGDS make use of
visual parts of SGDS (i.e. css), you do not need to import the following.
Install using npm
Frontend developers can use npm to download sgds and use it as a dependency in their projects.
Using npm is especially useful when using a module bundler or build tool for your frontend,
such as Webpack.
To see if npm is installed, open your preferred command line tool and
type in npm -v. This should print the npm version number
that look something like this 6.10.0
To install the sgds-govtech package, navigate to your site's codebase folder using
your terminal and run this command:
npm install sgds-govtech
This will download sgds into node_modules/sgds-govtech in your current folder:You can then load these assets into your frontend projects.
If you use a module bundler like Webpack, import sgds in your entry point:
*Note that usage with frameworks such as React, Vue or Angular is discouraged since they
manipulate the DOM in their own environments. Framework-specific
implementations are in early development and can be found at
in your production environment.
Extract and copy the files and folders into a relevant place in your
project’s code base
your project, same as above. Note that
certain components of SGDS make use of