{"id":40739,"library":"coffee-class-orm","title":"Coffee Class ORM","description":"An ORM for Node.js that uses CoffeeScript classes to interact with MySQL databases. Version 0.0.16 is the latest (as of 2015), with no active releases since. It is a lightweight, CoffeeScript-specific alternative to heavier ORMs like Sequelize. Designed for rapid prototyping with CoffeeScript, it directly maps class definitions to database tables. No longer maintained; exists primarily as an artifact of CoffeeScript's early popularity.","status":"abandoned","version":"0.0.16","language":"javascript","source_language":"en","source_url":"https://github.com/danschumann/coffee-class-orm","tags":["javascript"],"install":[{"cmd":"npm install coffee-class-orm","lang":"bash","label":"npm"},{"cmd":"yarn add coffee-class-orm","lang":"bash","label":"yarn"},{"cmd":"pnpm add coffee-class-orm","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"MySQL database driver required for database interaction","package":"mysql","optional":false}],"imports":[{"note":"Package is CJS only, but intended to be used with CoffeeScript's class syntax. ES import is not supported.","wrong":"const CoffeeORM = require('coffee-class-orm');","symbol":"CoffeeORM","correct":"import CoffeeORM from 'coffee-class-orm'"},{"note":"CoffeeORM exports a factory function, not a class; use CoffeeORM.Model as base.","wrong":"class User extends CoffeeORM","symbol":"Model","correct":"class User extends CoffeeORM.Model"},{"note":"No default export; use the function directly.","wrong":"require('coffee-class-orm').default","symbol":"CoffeeORM (default)","correct":"CoffeeORM = require('coffee-class-orm')"}],"quickstart":{"code":"CoffeeORM = require('coffee-class-orm')\n\nclass User extends CoffeeORM.Model\n  @table 'users'\n  @columns 'id', 'name', 'email'\n  @has_many 'posts'\n\nuser = new User(name: 'Alice')\nuser.save (err) ->\n  console.log 'Saved user', user.id","lang":"javascript","description":"Shows how to define a model with a database table, columns, associations, and save an instance."},"warnings":[{"fix":"Install CoffeeScript and use .coffee files or compile to JS.","message":"Package is CoffeeScript-only; requires CoffeeScript to be installed and .coffee files to be compiled at runtime or precompiled.","severity":"gotcha","affected_versions":"all"},{"fix":"Migrate to a maintained ORM like Sequelize or TypeORM.","message":"No updates since 2015; may have unpatched security vulnerabilities in dependencies.","severity":"deprecated","affected_versions":"all"},{"fix":"Use a different ORM for PostgreSQL, SQLite, etc.","message":"Only supports MySQL; no support for other databases.","severity":"breaking","affected_versions":"all"}],"env_vars":null,"search_vec":"'0.0.16':18 '2015':24 'activ':27 'altern':37 'artifact':64 'class':2,11,52 'coffe':1 'coffeescript':10,35,48,66 'coffeescript-specif':34 'databas':16,55 'definit':53 'design':43 'direct':50 'earli':68 'exist':60 'heavier':39 'interact':13 'javascript':70 'latest':21 'lightweight':33 'like':41 'longer':58 'maintain':59 'map':51 'mysql':15 'node.js':7 'orm':3,5,40 'popular':69 'primarili':61 'prototyp':46 'rapid':45 'releas':28 'sequel':42 'sinc':29 'specif':36 'tabl':56 'use':9 'version':17","created_at":"2026-06-04T18:49:00.830472+00:00","updated_at":"2026-06-04T18:49:00.830472+00:00","problems":[{"fix":"Run `npm install coffee-class-orm` and add `CoffeeORM = require('coffee-class-orm')` at top of file.","cause":"CoffeeORM not required or not installed","error":"ReferenceError: CoffeeORM is not defined"},{"fix":"Use `class User extends CoffeeORM.Model`; ensure CoffeeORM is required correctly.","cause":"CoffeeORM is not a function; Model is not a class","error":"TypeError: CoffeeORM.Model is not a constructor"},{"fix":"Run `npm install mysql` to add the peer dependency.","cause":"MySQL driver not installed","error":"Error: Cannot find module 'mysql'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/danschumann/coffee-class-orm","github":"https://github.com/danschumann/coffee-class-orm","docs":null,"changelog":null,"pypi":null,"npm":"coffee-class-orm","openapi_spec":null,"status_page":null,"smithery":null,"categories":["database"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-04","next_check":"2026-09-02","install_tag":null}}