Synclets logoSynclets

createMemoryDataConnector

The createMemoryDataConnector function creates an in-memory DataConnector that stores Atom data in a JavaScript Map.

createMemoryDataConnector<Depth>(options: MemoryDataConnectorOptions<Depth>): DataConnector<Depth>
TypeDescription
optionsMemoryDataConnectorOptions<Depth>
returnsDataConnector<Depth>

This connector provides fast, volatile storage that exists only during the current process lifetime. Data is lost when the process terminates or the Synclet is destroyed. It is primarily useful for testing, demos, temporary state, or as a fast cache layer in combination with persistent connectors.

The connector works in any JavaScript environment (Node.js, browsers, etc.) and has no external dependencies.

Since

v0.0.0