0.2.3 • Published 4 years ago

sails-firestore v0.2.3

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

sails-firestore

Provides easy access to Cloud Firestore from Sails.js & Waterline.

This module is a Sails/Waterline community adapter. Its goal is to provide a set of declarative interfaces, conventions, and best-practices for integrating with the Google Cloud Firestore database/service.

Strict adherence to an adapter specification enables the (re)use of built-in generic test suites, standardized documentation, reasonable expectations around the API for your users, and overall, a more pleasant development experience for everyone.

Installation

To install this adapter, run:

$ npm install sails-firestore

Then connect the adapter to one or more of your app's datastores.

Usage

// config/datastores.js
module.exports.datastores = {
  default: {
    adapter: 'sails-firestore',
    serviceAccount: require('../your-service-key')
  }
};

Visit Models & ORM in the docs for more information about using models, datastores, and adapters in your app/microservice.

Questions?

See Extending Sails > Adapters > Custom Adapters in the Sails documentation, or check out recommended support options.

Compatibility

This adapter implements the following methods:

MethodStatusCategory
registerDatastoreImplementedLIFECYCLE
teardown???LIFECYCLE
createImplementedDML
createEachImplementedDML
updateImplementedDML
destroyImplementedDML
findImplementedDQL
join???DQL
countImplementedDQL
sumImplementedDQL
avgImplementedDQL
define??DDL
dropImplementedDDL
setSequenceImplementedDDL

Query language

ModifierStatusRemark
<Implemented
<=Implemented
>Implemented
>=Implemented
==Implemented
!=Implemented
inImplemented
!inImplemented
containsImplementedclient-side
startsWithImplemented
endsWithImplementedclient-side
andImplemented
orImplemented
OptionStatusRemark
limitImplementedclient-side
sortImplementedclient-side
skipImplementedclient-side

You may see the test result here.

License

This firestore adapter is available under the MIT license.

As for Waterline and the Sails framework? They're free and open-source under the MIT License.

image_squidhome@2x.png