-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathcypress.config.ts
41 lines (37 loc) · 1.13 KB
/
cypress.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { defineConfig } from "cypress"
import react from "@vitejs/plugin-react"
import wasm from "vite-plugin-wasm"
import topLevelAwait from "vite-plugin-top-level-await"
export default defineConfig({
component: {
excludeSpecPattern: ["dist"],
devServer: {
framework: "react",
bundler: "vite",
viteConfig: {
plugins: [wasm(), topLevelAwait(), react()],
worker: {
format: "es",
plugins: [wasm(), topLevelAwait()],
},
optimizeDeps: {
// This is necessary because otherwise `vite dev` includes two separate
// versions of the JS wrapper. This causes problems because the JS
// wrapper has a module level variable to track JS side heap
// allocations, and initializing this twice causes horrible breakage
exclude: [
"@automerge/prosemirror",
"@automerge/automerge-wasm",
"@automerge/automerge-wasm/bundler/bindgen_bg.wasm",
"@syntect/wasm",
],
},
server: {
fs: {
strict: false,
},
},
},
},
},
})