Skip to content

medea/eu-medea-store

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

eu-medea-store

A Medea store for Eu.

Medea is an embedded key-value storage library written in pure JavaScript. Eu implements caching semantics on top of the request module. This module allows a persistent, cross-platform HTTP client cache that's 100% JavaScript. Yay!

Build Status

Example

var Eu = require('eu');
var medea = require('medea');
var MedeaStore = require('eu-medea-store');

var db = medea();
var store = new MedeaStore(db);
var cache = new Eu.Cache(store, 'test');

var eu = new Eu(cache);

db.open(function(err) {
  setInterval(function() {
    eu.get('http://some_url_with_cacheable_response', function(err, res) {
      console.log(res.headers['date']);
    });
  }, 1000);
});

License

MIT

About

A Medea store for Eu, a caching HTTP client.

Resources

License

Stars

Watchers

Forks

Packages

No packages published