Introducing PouchDB: The JavaScript database that Syncs
There are so many JavaScript caching database around, but if you are looking for something new and dynamic, go for PouchDB. This new minimalist JavaScript database allows you to build applications that work both offline and online. Besides, applications save data locally allowing you to use an app even offline, and synchronize data between clients so you have up to date data wherever you go. Isn’t it great?
PouchDB is Open Source, JavaScript minimal library, inspired by Apache CouchDB. The best part is that it is lightweight and easily embeddable. In fact, it is just a script tag. You can easily install it.
On web page:
Installation is simple, and putting it into the HTML of the website looks like this:
<script src="pouchdb-nightly.min.js"></script>
Once in place, it becomes easy to make use of the library to snychronize with the backend as needed.
On Node.js:
$ npm install pouchdb
Just as simple for Node.js.
For a HTTP API to PouchDB:
Check out PouchDB Server for HTTP support for Node.js; but this is a cross-platform library with availability for multiple platforms.
PouchDB uses various backends, such as IndexedDB in Firefox and Chrome, WebSQL in Safari and Opera and LevelDB in Node.js. It has been tested in different browsers:
- Firefox 12+
- Chrome 19+
- Opera 12+
- Safari 5+
- Node.js 0.10+
- Apache Cordova
- Internet Explorer 10+
If you’re interested in how to get started with PouchDB, there is a getting-started document to pore over as well as the full API documentation.
Since you’re here …
… We’d like to tell you about our mission and how you can help us fulfill it. SiliconANGLE Media Inc.’s business model is based on the intrinsic value of the content, not advertising. Unlike many online publications, we don’t have a paywall or run banner advertising, because we want to keep our journalism open, without influence or the need to chase traffic.The journalism, reporting and commentary on SiliconANGLE — along with live, unscripted video from our Silicon Valley studio and globe-trotting video teams at theCUBE — take a lot of hard work, time and money. Keeping the quality high requires the support of sponsors who are aligned with our vision of ad-free journalism content.
If you like the reporting, video interviews and other ad-free content here, please take a moment to check out a sample of the video content supported by our sponsors, tweet your support, and keep coming back to SiliconANGLE.