Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@blocksuite/store

Package Overview
Dependencies
Maintainers
2
Versions
1269
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@blocksuite/store - npm Package Compare versions

Comparing version 0.0.0-canary-20240904001311 to 0.0.0-canary-20240904094417

3

dist/store/collection.js

@@ -38,2 +38,3 @@ var __esDecorate = (this && this.__esDecorate) || function (ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {

import { AwarenessEngine, BlobEngine, DocEngine, MemoryBlobSource, NoopDocSource, } from '@blocksuite/sync';
import clonedeep from 'lodash.clonedeep';
import merge from 'lodash.merge';

@@ -93,3 +94,3 @@ import { Awareness } from 'y-protocols/awareness.js';

this.doc = new BlockSuiteDoc({ guid: id });
this.awarenessStore = new AwarenessStore(new Awareness(this.doc), merge({ ...FLAGS_PRESET }, defaultFlags));
this.awarenessStore = new AwarenessStore(new Awareness(this.doc), merge(clonedeep(FLAGS_PRESET), defaultFlags));
this.awarenessSync = new AwarenessEngine(this.awarenessStore.awareness, awarenessSources);

@@ -96,0 +97,0 @@ this.docSync = new DocEngine(this.doc, docSources.main, docSources.shadows ?? [], logger);

import { Slot } from '@blocksuite/global/utils';
import { signal } from '@preact/signals-core';
import clonedeep from 'lodash.clonedeep';
import merge from 'lodash.merge';

@@ -42,3 +43,3 @@ export class AwarenessStore {

const upstreamFlags = this.awareness.getLocalState()?.flags;
const flags = { ...defaultFlags };
const flags = clonedeep(defaultFlags);
if (upstreamFlags) {

@@ -45,0 +46,0 @@ merge(flags, upstreamFlags);

{
"name": "@blocksuite/store",
"version": "0.0.0-canary-20240904001311",
"version": "0.0.0-canary-20240904094417",
"description": "BlockSuite data store built for general purpose state management.",

@@ -16,2 +16,3 @@ "type": "module",

"lib0": "^0.2.97",
"lodash.clonedeep": "^4.5.0",
"lodash.ismatch": "^4.4.0",

@@ -23,7 +24,8 @@ "lodash.merge": "^4.6.2",

"zod": "^3.23.8",
"@blocksuite/global": "0.0.0-canary-20240904001311",
"@blocksuite/inline": "0.0.0-canary-20240904001311",
"@blocksuite/sync": "0.0.0-canary-20240904001311"
"@blocksuite/global": "0.0.0-canary-20240904094417",
"@blocksuite/inline": "0.0.0-canary-20240904094417",
"@blocksuite/sync": "0.0.0-canary-20240904094417"
},
"devDependencies": {
"@types/lodash.clonedeep": "^4.5.9",
"@types/lodash.merge": "^4.6.9",

@@ -30,0 +32,0 @@ "lit": "^3.2.0",

@@ -13,2 +13,3 @@ import { BlockSuiteError, ErrorCode } from '@blocksuite/global/exceptions';

} from '@blocksuite/sync';
import clonedeep from 'lodash.clonedeep';
import merge from 'lodash.merge';

@@ -122,3 +123,3 @@ import { Awareness } from 'y-protocols/awareness.js';

new Awareness<RawAwarenessState>(this.doc),
merge({ ...FLAGS_PRESET }, defaultFlags)
merge(clonedeep(FLAGS_PRESET), defaultFlags)
);

@@ -125,0 +126,0 @@

@@ -5,2 +5,3 @@ import type { Awareness as YAwareness } from 'y-protocols/awareness.js';

import { type Signal, signal } from '@preact/signals-core';
import clonedeep from 'lodash.clonedeep';
import merge from 'lodash.merge';

@@ -91,3 +92,3 @@

const upstreamFlags = this.awareness.getLocalState()?.flags;
const flags = { ...defaultFlags };
const flags = clonedeep(defaultFlags);
if (upstreamFlags) {

@@ -94,0 +95,0 @@ merge(flags, upstreamFlags);

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc