Skip to content

Commit ca66e8e

Browse files
authored
fix: loading all tabler-icon chunks in dev mode (#59)
Unnecessary tabler icon chunks are loaded in dev mode which causes the performance issue during development. This issue is solved by replacing the import alias for '@tabler/icons-react' in vite.config.ts Resolves #54
1 parent 8d3c83b commit ca66e8e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

vite.config.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ export default defineConfig({
99
resolve: {
1010
alias: {
1111
'@': path.resolve(__dirname, './src'),
12+
13+
// fix loading all icon chunks in dev mode
14+
// https://github.com/tabler/tabler-icons/issues/1233
15+
'@tabler/icons-react': '@tabler/icons-react/dist/esm/icons/index.mjs',
1216
},
1317
},
1418
})

0 commit comments

Comments
 (0)