Skip to content

Commit

Permalink
Chore(web-react): Do not list components that don't have index.html o…
Browse files Browse the repository at this point in the history
…n Demo homepage #DS-1185

Remove manually controlled list.
  • Loading branch information
crishpeen committed Feb 29, 2024
1 parent 0888f91 commit e4c2e0e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/web-react/config/vite/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ import { defineConfig } from 'vite';
import handlebars from 'vite-plugin-handlebars';
import { getNestedDirs } from '../../scripts/build';

const hiddenDemoComponents = ['Field', 'Dialog', 'Icon', 'NoSsr', 'TextFieldBase', 'VisuallyHidden'];

export default defineConfig({
// Disable HMR overlay to avoid flaky screenshots in visual regression tests
server: {
Expand All @@ -29,7 +27,7 @@ export default defineConfig({
components: [
...readdirSync('src/components', { withFileTypes: true })
.filter((item) => item.isDirectory())
.filter((item) => !hiddenDemoComponents.includes(item.name))
.filter((item) => readdirSync(`src/components/${item.name}`).includes('index.html'))
.map((item) => item.name),
],
},
Expand Down

0 comments on commit e4c2e0e

Please sign in to comment.