A didactic, lightweight ORM for Node.js inspired by Rails' ActiveRecord. Version 0.0.53 is the latest stable release. It supports SQLite via a JSON configuration file, provides basic CRUD operations, associations (belongsTo, hasMany), validations, and a simple migration system. Unlike large ORMs like Sequelize or TypeORM, this package focuses on simplicity and learning, with minimal abstraction. Release cadence is irregular—mainly minor patches. Key differentiator: pure JavaScript, no dependencies, and a single-file approach for learning ORM concepts.
npm install humble-node-ormNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic setup: define models with associations and validations, create a table, insert a record, and query all users.
Place the config file at the project root with the exact name.
Define associations in the constructor as shown in the docs. Do not define them as static methods.
Install globally: 'npm install -g humble-node-orm' then run 'humble-migrate' commands.
Call the validation function manually in your update logic or override the update method.
Use a different ORM for other databases.
Install the missing driver: 'npm install better-sqlite3'
Use ES6 import syntax: 'import { Model } from 'humble-node-orm''Create a valid 'node-orm.config.json' at the project root with SQLite type and database path.
Create the 'migrations' folder: 'mkdir migrations' or use 'humble-migrate migration:create' to generate files.