74af537800
In an attempt to make our package naming more understandable we move all our packages to a single NPM scope. `automerge` -> `@automerge/automerge` and `automerge-wasm` -> @automerge/automerge-wasm`
15 lines
573 B
JavaScript
15 lines
573 B
JavaScript
import { defineConfig } from "vite"
|
|
import wasm from "vite-plugin-wasm"
|
|
import topLevelAwait from "vite-plugin-top-level-await"
|
|
|
|
export default defineConfig({
|
|
plugins: [topLevelAwait(), wasm()],
|
|
|
|
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, initializing this twice causes horrible breakage
|
|
exclude: ["@automerge/automerge-wasm"]
|
|
}
|
|
})
|