hero

Lotion

Smooth, easy blockchain apps. Powered by Tendermint consensus.

Get Started →

Simple

Build a new cryptocurrency or DAO in just a few lines of code.

JavaScript

Build blockchain apps in the language of the web. Use any NPM module.

Tendermint

Write secure, scalable, interoperable blockchains on the Cosmos Network.

1. Install

$ npm install lotion

2. Write your state machine

// app.js
let lotion = require('lotion')

let app = lotion({
	initialState: {
		count: 0
	}
})

app.use(function(state, tx) {
	if (state.count === tx.nonce) {
		state.count++
	}
})

app.start().then(function(appInfo) {
	console.log(`app started. gci: ${appInfo.GCI}`)
})

3. Run it and query the state

$ node app

# in another terminal:

$ npx lotion-cli state <GCI>