- If you haven't already cloned the repository, do so by running the following in your command line:
git clone https://bitbucket.org/uclaucomm/ucla-bruin-components.git
- Navigate to your local copy:
cd ucla-bruin-components
- Make sure
node
,npm
, andgulp
have been installed successfully.
node -v
npm -v
gulp -v
-
Install package dependencies:
npm install
-
Run first fractal build
npm run prepare
-
Run Fractal and watch any changes:
fractal build
fractal start --sync
Your local environment should be running at http://localhost:3000.
-
Run Gulp to transpile stylesheets and scripts.
gulp build
gulp watch
-
Run SVGO to process svg files
svgo -f ./src/icons/**/* -o ./public/icons/**/*
-
Helpful sass commands if you prefer to not rely on gulp
sass src/scss/ucla-styles.scss public/css/ucla-styles.css
sass src/docs/scss/ucla-fractal-style.scss public/css/ucla-fractal-style.css
Task | Description |
---|---|
build |
Build Fractal framework, build expanded styling and scripts for both documentation and components library, and remove string filters (used for production versioning) |
watch |
Start Fractal development web server, watch for styling and script changes for both the documentation and components library, and run linters for both the documentation and components library |
*production |
Build Fractal framework and build compressed styling and scripts for both documentation and components library |
*addImageFilterStrs |
Add filter string for images |
*used in production builds and should only be used locally to test behaviors expected in production