Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 1,000,000+ packages pre-installed, including data-path-store with all npm packages installed. Try it out:

// Get the store var store = require("data-path-store"); store = new store(); // Setup update listener store.on("change", function(val) { console.log(val); }); // Add function for generating data store.setData("clicheGreetings", "hello", function(params, cb) { return "Hello, " + params + "!"; }); // Have some fun var thor = await store.getData("clicheGreetings", "hello", "Thor"); // Hello, Thor! var loki = await store.getData("clicheGreetings", "hello", "Loki"); // Hello, Loki! var oNeill = await store.getData("clicheGreetings", "hello", "O'Neill"); // Hello, O'Neill! // Cache them as an array in the store (Trigers update function above) store.setData("greetings", "people", [thor.data, loki.data, oNeill.data]);

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

data-path-store v2.0.1

In-memory path based data store which can be hooked into

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free