diff options
author | Matthew Strapp <matt@mattstrapp.net> | 2024-11-01 10:16:44 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-01 10:16:44 -0500 |
commit | 9c3cef2cda489501a177c34ebe47951321284463 (patch) | |
tree | a6b45cdef7acde058ee033c386b93fa819e15c36 /src/packages/react/vite.config.ts | |
parent | badge bleach (diff) | |
download | locusts-9c3cef2cda489501a177c34ebe47951321284463.tar locusts-9c3cef2cda489501a177c34ebe47951321284463.tar.gz locusts-9c3cef2cda489501a177c34ebe47951321284463.tar.bz2 locusts-9c3cef2cda489501a177c34ebe47951321284463.tar.lz locusts-9c3cef2cda489501a177c34ebe47951321284463.tar.xz locusts-9c3cef2cda489501a177c34ebe47951321284463.tar.zst locusts-9c3cef2cda489501a177c34ebe47951321284463.zip |
feat: Add React (#38)
* feat: Add React
Closes #35
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
* lint
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
* docs
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
* lint
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
* add keywords
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
---------
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to 'src/packages/react/vite.config.ts')
-rw-r--r-- | src/packages/react/vite.config.ts | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/packages/react/vite.config.ts b/src/packages/react/vite.config.ts new file mode 100644 index 0000000..d43457e --- /dev/null +++ b/src/packages/react/vite.config.ts @@ -0,0 +1,22 @@ +import { defineConfig } from "vite"; +import react from "@vitejs/plugin-react-swc"; + +// https://vite.dev/config/ +export default defineConfig({ + plugins: [react()], + build: { + lib: { + entry: "src/index.ts", + name: "Locusts", + fileName: "locusts", + }, + rollupOptions: { + external: ["react"], + output: { + globals: { + react: "React", + }, + }, + }, + }, +}); |