Skip to content

Commit b5c393a

Browse files
gzioloepiqueras
authored andcommitted
Framework: Add Component Storybook (tweaks) (WordPress#17762)
* Experimenting with the repository setup * Add more tweaks
1 parent bc005b9 commit b5c393a

File tree

10 files changed

+292
-1133
lines changed

10 files changed

+292
-1133
lines changed

.eslintrc.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,9 @@ module.exports = {
121121
},
122122
excludedFiles: [
123123
'**/*.@(android|ios|native).js',
124-
'**/@(benchmark|test|__tests__)/**/*.js',
125-
'**/{storybook,stories}\/*\.js',
124+
'**/benchmark/**/*.js',
125+
'**/@(__mocks__|__tests__|test)/**/*.js',
126+
'**/storybook/**/*.js',
126127
],
127128
},
128129
{

.travis.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -199,8 +199,9 @@ jobs:
199199
if: branch = master
200200
name: Deploy Playground
201201
env: INSTALL_WORDPRESS=false
202+
install:
203+
- npm ci
202204
before_deploy:
203-
- npm install
204205
- npm run playground:build -- --public-url '/gutenberg'
205206
- npm run design-system:build
206207
deploy:

bin/packages/build.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,9 @@ if ( files.length ) {
126126
`${ PACKAGES_DIR }/*/src/*.scss`,
127127
], {
128128
ignore: [
129-
`**/test/**`,
130-
`**/__mocks__/**`,
129+
`**/benchmark/**`,
130+
`**/{__mocks__,__tests__,test}/**`,
131+
`**/{storybook,stories}/**`,
131132
],
132133
onlyFiles: true,
133134
} );

bin/packages/watch.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const exists = ( filename ) => {
2727
// and files with a suffix of .test or .spec (e.g. blocks.test.js),
2828
// and deceitful source-like files, such as editor swap files.
2929
const isSourceFile = ( filename ) => {
30-
return ! [ /\/(__tests__|test)\/.+.js$/, /.\.(spec|test)\.js$/ ].some( ( regex ) => regex.test( filename ) ) && /.\.(js|json|scss)$/.test( filename );
30+
return ! [ /\/(benchmark|__mocks__|__tests__|test|storybook|stories)\/.+.js$/, /.\.(spec|test)\.js$/ ].some( ( regex ) => regex.test( filename ) ) && /.\.(js|json|scss)$/.test( filename );
3131
};
3232

3333
const rebuild = ( filename ) => filesToBuild.set( filename, true );

lerna.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"ignoreChanges": [
88
"**/benchmark/*.js",
99
"**/CHANGELOG.md",
10-
"**/test/**",
10+
"**/{__mocks__,__tests__,test}/**",
1111
"**/{storybook,stories}/**"
1212
],
1313
"packages": [

0 commit comments

Comments
 (0)