New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

jsonapi-express-backend

Package Overview
Dependencies
Maintainers
1
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsonapi-express-backend

Track projects and time with Express and AngularJS

  • 0.3.5
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

JSONAPI Express.js / MySQL backend

Fair bit of warning

This is work in progress, and not production-ready (yet). That being said, it does the job, for me at least :).

Please don't hesitate to contact me if you run into issues while giving this project a try. As I am currently working on it heavily, I will definitely answer your request. Besides, documentation is on its way, a user guide will be provided soon.

About this project

This project began as a standalone Express app, that I just started turning into an NPM module.

The motivation for it is to have a simple-to-use backend for Ember.js.

An example project is available at https://github.com/bhubr/jsonapi-express-backend-demo. It demonstrates how to configure the module by providing those parameters:

  • public&private keys path
  • db settings
  • model relationships descriptors

Install

npm install --save jsonapi-express-backend

Features

  • MySQL support. Works with MariaDB (actually only tested on MariaDB). More (PostgreSQL) might come after.
  • Dead-simple. No ORM, but simple query-building using Squel.
  • Uses JSON Web Tokens for authentication.
  • Supports one-to-one, one-to-many, many-to-many model relationships.

Limitations

  • As of now, you have to create your MySQL schema by hand. It has to respect some conventions as to table and field naming:
    • primary key for all tables is id
    • each data type (that is, all tables but the pivot tables) must have createdAt and updatedAt fields.

TODO

  • Don't query all the fields for relationships when I need only the id.
  • Implement an "event hub" and fire events on DB record creation/update/deletion.
  • Allow filtering of the returned fields.
  • Implement refresh of the JWT.

FAQs

Package last updated on 12 Apr 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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