This repo is for Lux version 4 and earlier. For current releases of Lux, please see the Lux Design System documentation or code repository.
# this will add the latest official release
yarn add lux-design-system
If you are looking to integrate LUX into an existing Rails, Drupal, or even JSFiddle, check out our documentation for How to Install LUX.
...
"dependencies": {
"lux-design-system": "pulibrary/lux"
}
...
...
"dependencies": {
"lux-design-system": "^0.0.0"
}
...
yarn build:static
Then use <script/>
and <link/>
tags to include to the js and css files in the static/system
directory in your HTML. Then include any LUX components in a wrapper with class="lux"
.
- You will need Node v10.16.0+
- If you use a NVM, run
nvm install
ornvm use
if you already know you have Node v10.16.0
yarn install
yarn start
yarn test
yarn unit mytest.spec.js
You might want to develop LUX while developing on a project that uses LUX as a dependency. For example, you might want to develop LUX components while developing the Approvals app. NOTE: You will need to have both LUX and the project using it as a dependency running on your machine.
- Install yalc
- In the LUX root directory, run
yarn build:system && yalc publish
- In the Project (e.g., Approvals) root directory, run
yalc add lux-design-system
- Each time that you are ready to view the LUX work in progress, run the last 2 steps:
- In the LUX root directory, run
yarn build:system && yalc publish
- In the Project (e.g., Approvals) root directory, run
yalc update
- In the LUX root directory, run
To deploy docs:
# make sure git status is clean with no uncommitted modified files
yarn run deploy
- If you don't already have np installed,
yarn global add np
. If you are running an old version of node (e.g. Node 12), you may need to install an older version of np (e.g.yarn global add np@6.5.0
) - If you have a passphrase on your ssh key, run
ssh-add ~/.ssh/id_ed25519
(or wherever your key is located). - If you use a security key, rather than an authenticator app, for two-factor authentication in npmjs.com, make sure that "Require two-factor authentication for write actions" is not checked in your account 2FA settings. If it is checked, np will ask you for an OTP from your phone, and won't allow you to push without it.
- Pull latest main with merged changes.
- Run
yarn login
- Run
yarn release
- 🎉