mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-10-03 00:27:30 -05:00
Move app to apps/web-react in pnpm workspace layout
This commit is contained in:
18
apps/web-react/scripts/scanner/vite-node.config.ts
Normal file
18
apps/web-react/scripts/scanner/vite-node.config.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
/**
|
||||
* Config for running the scanner scripts with vite-node. Deliberately minimal:
|
||||
* the root vite.config.ts pre-bundles @techstark/opencv-js for the browser
|
||||
* worker, and vite-node would resolve that browser prebundle (which
|
||||
* crashes on __dirname in Node). Without the include, vite-node
|
||||
* externalizes the dep to a plain require of the (patched) CJS bundle.
|
||||
*/
|
||||
import { defineConfig } from "vite";
|
||||
|
||||
export default defineConfig({
|
||||
resolve: {
|
||||
tsconfigPaths: true,
|
||||
},
|
||||
optimizeDeps: {
|
||||
noDiscovery: true,
|
||||
exclude: ["@techstark/opencv-js"],
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user