Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

botl

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

botl

bOTL: Object Transformation Language for Javascript

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

bOTL.js

bOTL Object Transformation Language v3 It's Mustache for JSON

This is a JavaScript implementation of bOTL v3.

Get started by reading the bOTL specification at Medium.

Usage

Node.js

const botl = require("botl");

let source = {"name": "Freddo"};
let transform = "#$.name";

let result = botl.transform(source, transform);
// result: "Freddo" 

Web

Just grab the file bOTL.js and use it like this:

<script type="text/javascript" src="bOTL.js"></script>

<script>
  let source = {"name": "Freddo"};
  let transform = "#$.name";

  let result = bOTL.transform(source, transform);
  // result: "Freddo"
</script>

Using Github as a CDN

Don't want to download anything at all? Try this fiddle. Note that this uses a Github Pages url (https://emlynoregan.github.io/bOTL_js/bOTL.js), which has usage limits.

Miscelaneous

You can also use a package manager like yarn, npm or bower (deprecated).

Acknowledgements

bOTL.js includes Stefan Goessner's JSONPath implementation, released under an MIT license.

Keywords

FAQs

Package last updated on 08 Jan 2018

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