Support and Documentation

Building a theme

Procedure. To build a theme:
  1. Change to the directory you cloned from github.

    . 1 ├── README.md ├── _build/ │ └── brightspot-theme-frost-x.x.x-SNAPSHOT.zip 2 ├── babel.config.js ├── com/ ├── etc/ ├── gulpfile.js ├── node_modules/ ├── package.json ├── postcss.config.js ├── styleguide/ ├── webpack.*.js └── yarn.lock

    1

    Directory from which you run the build or start the server.

    2

    Built theme.

  2. If you want to build the theme and run the Styleguide server, run yarn server:styleguide.

  3. If you want to build the theme without running the Styleguide server—

    • For the first build, run yarn cache clean && yarn && yarn format && yarn build.

    • For subsequent builds, run yarn build.

The build job creates and zips the theme in the directory build/ (see previous illustration). You can apply the built theme to a site; for details, see Changing a site's theme.