Skip to content

Commit

Permalink
chore: JSX pragma 전역 설정 세팅
Browse files Browse the repository at this point in the history
  • Loading branch information
bongtta committed Nov 20, 2024
1 parent 92865b3 commit cca2723
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 7 deletions.
1 change: 1 addition & 0 deletions tsconfig.app.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"lib": ["ES2020", "DOM", "DOM.Iterable"],
"module": "ESNext",
"skipLibCheck": true,
"jsxImportSource": "@emotion/react",

/* Bundler mode */
"moduleResolution": "Bundler",
Expand Down
6 changes: 5 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,9 @@
"references": [
{ "path": "./tsconfig.app.json" },
{ "path": "./tsconfig.node.json" }
]
],
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "@emotion/react"
}
}
18 changes: 12 additions & 6 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react-swc";
import tsconfigPaths from "vite-tsconfig-paths";
import svgr from "vite-plugin-svgr";
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react-swc';
import tsconfigPaths from 'vite-tsconfig-paths';
import svgr from 'vite-plugin-svgr';

// https://vite.dev/config/
export default defineConfig({
plugins: [react(), tsconfigPaths(), svgr()],
plugins: [
react({
jsxImportSource: '@emotion/react',
}),
tsconfigPaths(),
svgr(),
],
resolve: {
extensions: [".js", ".jsx", ".ts", ".tsx"],
extensions: ['.js', '.jsx', '.ts', '.tsx'],
},
});

0 comments on commit cca2723

Please sign in to comment.