Warning
Some of this has changes since this original implementation to improve some problematic aspects. Check the latest related code for comparison.
How we initially installed the USWDS v3.4.1 package in our Angular 16 site
Create a new Angular 16 application with ng new
Install USWDS into the application with npm install --save uswds@3.4.1
Add the USWDS assets in angular.json with glob pattern, to copy static fonts and images
Add the USWDS includePaths for referencing the package SASS sources
Add the USWDS custom setting, reference, and customized SCSS files to the entry SASS/styles.scss file, then reference it in the angular.jsonstyles section of angular.json
Add the minified USWDS JavaScript path to the angular.json file scripts section
In any utilized USWDS template HTML, update static file paths, if different
How we initially installed the USWDS v3.4.1 package in our Angular 16 site
ng new
npm install --save uswds@3.4.1
angular.json
withglob
pattern, to copy static fonts and imagesincludePaths
for referencing the package SASS sourcesSASS/styles.scss
file, then reference it in theangular.json
styles
section ofangular.json
angular.json
filescripts
section