Skip to content

Commit c612b7b

Browse files
authored
chore(upgrade): upgrade deps (#103)
use localhost instead of 0.0.0.0 for host so app opens correctly on windows use enzyme-adapter-react-17 to ensure jest test works remove stub async module support prevent url from changing when selecting SkipToContent component update readme screenshot preview patch storybook
1 parent 015ddf4 commit c612b7b

File tree

13 files changed

+6987
-9378
lines changed

13 files changed

+6987
-9378
lines changed

.storybook/webpack.config.js

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,16 @@
11
const path = require('path');
22
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
33
const appConfig = require('../webpack.common');
4+
const { stylePaths } = require("../stylePaths");
45

56
module.exports = ({ config, mode }) => {
67
config.module.rules = [];
78
config.module.rules.push(...appConfig(mode).module.rules);
89
config.module.rules.push({
910
test: /\.css$/,
1011
include: [
11-
path.resolve(__dirname, '../src'),
1212
path.resolve(__dirname, '../node_modules/@storybook'),
13-
path.resolve(__dirname, '../node_modules/patternfly'),
14-
path.resolve(__dirname, '../node_modules/@patternfly/patternfly'),
15-
path.resolve(__dirname, '../node_modules/@patternfly/react-styles/css'),
16-
path.resolve(__dirname, '../node_modules/@patternfly/react-core/dist/styles/base.css'),
17-
path.resolve(__dirname, '../node_modules/@patternfly/react-core/dist/esm/@patternfly/patternfly'),
18-
path.resolve(__dirname, '../node_modules/@patternfly/react-core/node_modules/@patternfly/react-styles/css'),
19-
path.resolve(__dirname, '../node_modules/@patternfly/react-table/node_modules/@patternfly/react-styles/css'),
20-
path.resolve(__dirname, '../node_modules/@patternfly/react-inline-edit-extension/node_modules/@patternfly/react-styles/css')
13+
...stylePaths
2114
],
2215
use: ["style-loader", "css-loader"]
2316
});

README.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ Patternfly Seed is an open source build scaffolding utility for web apps. The pr
44

55
Out of the box you'll get an app layout with chrome (header/sidebar), routing, build pipeline, test suite, and some code quality tools. Basically, all the essentials.
66

7-
<img width="1058" alt="Out of box dashboard view of patternfly seed" src="https://user-images.githubusercontent.com/5942899/82119580-b4cf9380-974d-11ea-9f13-fa10471c5c73.png">
7+
<img width="1058" alt="Out of box dashboard view of patternfly seed" src="https://user-images.githubusercontent.com/5942899/103803761-03a0a500-501f-11eb-870a-345d7d035e6b.png">
88

99
## Quick-start
1010

1111
```bash
1212
git clone https://github.com/patternfly/patternfly-react-seed
13-
cd patternfly-react-seed
14-
npm install && npm run start:dev
13+
cd patternfly-react-seed
14+
npm install && npm run start:dev
1515
```
16-
## Development Scripts
16+
## Development scripts
1717
```sh
1818
# Install development/build dependencies
1919
npm install
@@ -52,7 +52,7 @@ npm run build:storybook
5252
* [Jest Config](./jest.config.js)
5353
* [Editor Config](./.editorconfig)
5454

55-
## Raster Image Support
55+
## Raster image support
5656

5757
To use an image asset that's shipped with PatternFly core, you'll prefix the paths with "@assets". `@assets` is an alias for the PatternFly assets directory in node_modules.
5858

@@ -69,7 +69,7 @@ import loader from '@app/assets/images/loader.gif';
6969
<img src={loader} alt="Content loading />
7070
```
7171
72-
## Vector Image Support
72+
## Vector image support
7373
Inlining SVG in the app's markup is also possible.
7474
7575
```js
@@ -84,7 +84,10 @@ body {
8484
}
8585
```
8686
87-
## Code Quality Tools
87+
## Adding custom CSS
88+
When importing CSS from a third-party package for the first time, you may encounter the error `Module parse failed: Unexpected token... You may need an appropriate loader to handle this file typ...`. You need to register the path to the stylesheet directory in [stylePaths.js](./stylePaths.js). We specify these explicity for performance reasons to avoid webpack needing to crawl through the entire node_modules directory when parsing CSS modules.
89+
90+
## Code quality tools
8891
* For accessibility compliance, we use [react-axe](https://github.com/dequelabs/react-axe)
8992
* To keep our bundle size in check, we use [webpack-bundle-analyzer](https://github.com/webpack-contrib/webpack-bundle-analyzer)
9093
* To keep our code formatting in check, we use [prettier](https://github.com/prettier/prettier)

0 commit comments

Comments
 (0)