diff options
author | Kristóf Marussy <kristof@marussy.com> | 2021-12-23 13:40:47 +0100 |
---|---|---|
committer | Kristóf Marussy <kristof@marussy.com> | 2021-12-23 15:48:30 +0100 |
commit | 950fb9be8061e2a26e0536b98c6a3ee230618f54 (patch) | |
tree | b136dcc9add0d268a2e7a6288ec934a86d03b652 /packages/renderer/vite.config.js | |
parent | feat: Add shared package for electron ipc (diff) | |
download | sophie-950fb9be8061e2a26e0536b98c6a3ee230618f54.tar.gz sophie-950fb9be8061e2a26e0536b98c6a3ee230618f54.tar.zst sophie-950fb9be8061e2a26e0536b98c6a3ee230618f54.zip |
feat: Main to renderer store synchronization
Patches are send in one direction only, from the main to the renderer,
so all actions have to go through the context bridge and the renderer
IPC to modify the store in the renderer. This makes the store in the
main process a single source of truth, which simplifies debugging and
state persistence.
The store in the renderer is connected to redux devtools for inspection,
but playing back the state in the devtools won't change the sotre in
main process.
Diffstat (limited to 'packages/renderer/vite.config.js')
-rw-r--r-- | packages/renderer/vite.config.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/renderer/vite.config.js b/packages/renderer/vite.config.js index ff34b6d..87c2d0c 100644 --- a/packages/renderer/vite.config.js +++ b/packages/renderer/vite.config.js | |||
@@ -3,7 +3,6 @@ | |||
3 | /* eslint-env node */ | 3 | /* eslint-env node */ |
4 | 4 | ||
5 | import { builtinModules } from 'module'; | 5 | import { builtinModules } from 'module'; |
6 | import { join } from 'path'; | ||
7 | import react from '@vitejs/plugin-react'; | 6 | import react from '@vitejs/plugin-react'; |
8 | 7 | ||
9 | // `resolveJsonModule` is disabled for this package, but vite will load the json nevertheless. | 8 | // `resolveJsonModule` is disabled for this package, but vite will load the json nevertheless. |
@@ -36,6 +35,8 @@ const config = { | |||
36 | assetsDir: '.', | 35 | assetsDir: '.', |
37 | rollupOptions: { | 36 | rollupOptions: { |
38 | external: [ | 37 | external: [ |
38 | 'mst-middlewares', | ||
39 | 'remotedev', | ||
39 | ...builtinModules, | 40 | ...builtinModules, |
40 | ], | 41 | ], |
41 | }, | 42 | }, |