Skip to content

arnoutaertgeerts/ng-pouch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ng-pouch

Full stack angular app using pouchDB/couchDB to store data and handle security. The app is a boilerplate to quickly start an angular web-app with a backend which tries to be as independent of a server as possible.

Installation

The core of the app is an angular app served by a minimal express app. To deploy the app, clone the repository:

git clone https://github.com/arnoutaertgeerts/ng-pouch/ myApp

Navigate to the client directory and install the client dependencies:

cd myApp/client
bower install
npm install

Navigate to the serverdirectory and install the server dependencies:

cd ../server
npm install

Serve the app using node or nodemon

nodemon server.js

Guide<a name="guide>

The Angular app

The angular app is served by a minimal express server and tries to be as independent of the express app as possible. Almost all requests are send directly to a CouchDB instance using PouchDB. Requests are handled by the angular-sofa module. This module contains two main factories:

  • The Sync factory: Used to sync a local PouchDB database with a remote CouchDB database. This factory allows live updating.
  • The Model factory: Used to interact with a remote CouchDB database as with a REST api.

CouchDB configuration

The app tries to leverage the extra features of CouchDB as much as possible. This includes

  • Views
  • Security through validation documents
  • Filters for filtered syncing to the local database

Stack

We make use of the following technologies:

Inspiration

This project is heavily inspired by

About

Angular app using CouchDB as backend with PouchDB

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published