@ramifyjs/core
v0.0.4
Published
Reactive, in-memory database for JavaScript applications.
Maintainers
Readme
@ramifyjs/core
Reactive, in-memory database for JavaScript applications.
Ramify JS is environment-agnostic—built for the browser, Node.js, and Edge runtimes. It provides a lightweight, type-safe data store with live query observation for building reactive applications.
Install
npm install @ramifyjs/core
# or
pnpm add @ramifyjs/core
# or
yarn add @ramifyjs/coreUsage
import { Ramify, type Schema } from '@ramifyjs/core';
// 1. Define your schema
const schema = {
users: {
primaryKey: 'id',
indexes: ['email'],
},
};
// 2. Create the store
const db = new Ramify().createStore<{ users: Schema<User, 'id'> }>(schema);
// 3. Simple operations
db.users.put({ id: 1, name: 'John Doe', email: '[email protected]' });
const user = db.users.where({ email: '[email protected]' }).first();
console.log(user); // { id: 1, name: 'John Doe', email: '[email protected]' }Features
- Type-safe: Full TypeScript support with schema-based type inference.
- Reactive: Observe changes with live queries.
- Fast: In-memory operations for high-performance data access.
- Environment Agnostic: Works in Browser, Node.js, and Edge.
