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

sofajs

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sofajs

couchdb interface builder

  • 0.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

sofajs

not ready for production -- test coverage 89%.

Build couchdb request logic using sofajs which loads all requests into a requests object for easy consumption within your application. Plus, documentation is generated for all requests supporting gfm.

Install

npm install sofajs

Why sofajs?

While planning for a hapijs project which used CouchDB saw something like sofajs was needed so decided to build it.

Designs

A core concept of couchDB is orgnizing and searching your data using design documents. sofajs supports the construction of views and update functions and generates design documents for you. Plus, the design document builder logic supports the loading of fixture data for each design document.

DB Connections

sofajs uses nano when making couchdb requests. A database connection is guaranteed before requests are executed. And, nano's database methods can be accessed using: sofaInternals.db object.

Three types of methods

sofajs provides tools to build three types of methods: requests, tools, and promises.

  • database requests methods
    methods that your nodejs application will use when making a request to CouchDB. Accessible to externally to be used by applications consuming the object.
  • tools or helper methods
    These are helper methods used inside database request methods. They are not accessible applications consuming the sofajs object.
  • promises methods
    Promises functions stored in sofajs object.

Grouping of methods

methods are grouped by lables you create. For example, a group named 'user' could be created and the sofajs object would have:

  • sofaInternals.requests.user
    all request methods build for the user group would be in the sofaInternals.requests.user object.
  • sofaInternals.tools.user
    all tool methods built for the user group would be in the sofaInternals.tools.user object.
  • sofaInternals.promises.user

    all promise methods built for the user group would be in the sofaInternals.promises.user object.

Documentation Server

supports a documentation server which generates html documenation using hapijs.

Testing

require 100% test coverage using: lab and code

Style Guide

Project follows: hapijs coding conventions

Keywords

FAQs

Package last updated on 20 Oct 2015

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