Skip to content
This repository was archived by the owner on Apr 28, 2020. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions docs/DevGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,9 @@ This project uses the [BEM (Block Element Modifier)](http://getbem.com/naming/)
for CSS classes. Refer to [stylelint configuration](../config/stylelint.config.js) for details
on project-specific BEM format.

For each React component group, there may be multiple logical BEM-style selectors. Taking
`src/components/Form/FormFactory` as an example, this component's render output includes
PF-React's `FormGroup` with CSS class `kubevirt-form-group` added to it. In other words,
different logical parts of the given component may use different CSS classes.
Each file at `sass/components/<GroupName>` represents a specific BEM block. For example,
`sass/components/Form/dropdown.scss` should only include CSS selectors that start with
`.kubevirt-dropdown`.

## Cosmos

Expand Down Expand Up @@ -109,6 +108,12 @@ module.exports = () => {
yarn test
```

### Do a development build without any pre-checks?

```sh
yarn dev
```

### Run specific tests?

```sh
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@
"test": "yarn jest",
"test:watch": "yarn test --watch",
"prebuild": "yarn test --ci && shx rm -rf dist",
"build": "yarn build:js && yarn build:sass",
"build": "NODE_ENV=production yarn build:js && yarn build:sass",
"build:js": "babel src --config-file ./config/babel.config.js --out-dir dist/js --only 'src/**/*.js' --ignore 'src/jest,src/cosmos,**/tests/**,**/fixtures/**'",
"build:sass": "shx cp -r sass dist",
"dev": "shx rm -rf dist && NODE_ENV=development yarn build:js && yarn build:sass",
"jest": "jest --config config/jest.config.js",
"cosmos": "cosmos --config config/cosmos.config.js",
"cosmos:export": "shx rm -rf cosmos && NODE_ENV=production cosmos-export --config config/cosmos.config.js",
Expand Down