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

babel-plugin-isotropy-keyvaluedb

Package Overview
Dependencies
Maintainers
4
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-isotropy-keyvaluedb

Babel plugin for transforming to lib-keyvaluedb

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-87.5%
Maintainers
4
Weekly downloads
 
Created
Source

Isotropy Babel Plugin for Key-Value-DB

This module is a babel plugin that transpiles array operations into corresponding kv-db operations. It uses isotropy-ast-analyzer-keyvaluedb for AST analysis.

This is part of the isotropy framework (www.isotropy.org).

Include the plugin in .babelrc file.

Plugin configuration:

plugins: [
  [
    "transform-to-isotropy-keyvalueb",
    {
      projects: [
        {
          dir: "dist/test",
          modules: [
            {
              source: "fixtures/my-db",
              locations: [
                { name: "todos", connStr: "redis://127.0.0.1:6379" }
              ]
            }
          ]
        }
      ]
    }
  ]
]

projects:
dir: Specify the root of the project.
modules:
source: Points to the local db file.
locations:
name: The name used to access the connStr specified alongside.
connStr: The connection string used when the actual database operations take place.

Example:

import myDb from "./my-db";

async function getTodos() {
  // return all keyvalue pairs in "redis://127.0.0.1:6379"
  return myDb.todos
}

FAQs

Package last updated on 29 Oct 2017

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