Skip to content

Commit

Permalink
feat: use vite-plugin-svgr for react svgs
Browse files Browse the repository at this point in the history
  • Loading branch information
quentinderoubaix committed Feb 13, 2024
1 parent f2d4e34 commit e4f75c6
Show file tree
Hide file tree
Showing 13 changed files with 786 additions and 46 deletions.
471 changes: 470 additions & 1 deletion demo/src/lib/stackblitz/react/package-lock.json

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion demo/src/lib/stackblitz/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"sass": "^1.70.0",
"tslib": "^2.6.2",
"typescript": "~5.3.3",
"vite": "^5.1.1"
"vite": "^5.1.1",
"vite-plugin-svgr": "^4.2.0"
}
}
1 change: 1 addition & 0 deletions demo/src/lib/stackblitz/react/src/vite-env.d.ts
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/// <reference types="vite-plugin-svgr/client" />
/// <reference types="vite/client" />
3 changes: 2 additions & 1 deletion demo/src/lib/stackblitz/react/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import {defineConfig} from 'vite';
import svgr from 'vite-plugin-svgr';
import react from '@vitejs/plugin-react';

// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
plugins: [svgr(), react()],
});
268 changes: 267 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions react/demo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,12 @@
"eslint-plugin-react": "^7.33.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router-dom": "^6.22.0"
"react-router-dom": "^6.22.0",
"vite-plugin-svgr": "^4.2.0"
},
"dependencies": {
"@agnos-ui/react-headless": "*",
"@agnos-ui/react": "*",
"@agnos-ui/react-headless": "*",
"@agnos-ui/style-bootstrap": "*",
"@amadeus-it-group/tansu": "1.0.0",
"@floating-ui/dom": "^1.6.2",
Expand Down
Loading

0 comments on commit e4f75c6

Please sign in to comment.