Add crdt as a separate package

This commit is contained in:
Hakan Shehu
2024-11-07 09:32:26 +01:00
parent 8a5409ad29
commit 3042625e34
11 changed files with 130 additions and 61 deletions

View File

@@ -6,7 +6,7 @@ export default defineConfig({
main: {
plugins: [
externalizeDepsPlugin({
exclude: ['@colanode/core'],
exclude: ['@colanode/core', '@colanode/crdt'],
}),
],
resolve: {
@@ -20,7 +20,11 @@ export default defineConfig({
},
},
preload: {
plugins: [externalizeDepsPlugin()],
plugins: [
externalizeDepsPlugin({
exclude: ['@colanode/core', '@colanode/crdt'],
}),
],
resolve: {
alias: {
'@/lib': resolve('src/lib'),

View File

@@ -21,6 +21,7 @@
},
"dependencies": {
"@colanode/core": "workspace:*",
"@colanode/crdt": "workspace:*",
"@electron-toolkit/preload": "^3.0.1",
"@electron-toolkit/utils": "^3.0.0",
"@hookform/resolvers": "^3.9.0",

View File

@@ -1,5 +1,6 @@
import * as Y from 'yjs';
import { NodeAttributes, registry, applyCrdt } from '@colanode/core';
import { NodeAttributes, registry } from '@colanode/core';
import { applyCrdt } from '@colanode/crdt';
import { fromUint8Array, toUint8Array } from 'js-base64';
import {
LocalCreateNodeChangeData,

View File

@@ -2,6 +2,7 @@
"files": [],
"references": [
{ "path": "../../packages/core/tsconfig.json" },
{ "path": "../../packages/crdt/tsconfig.json" },
{ "path": "./tsconfig.node.json" },
{ "path": "./tsconfig.web.json" }
]