PlantUML encoder for browsers and Node.js.
Encoded PlantUML can be used to create PlantUML URL links. It resolves PlantUML 'include' statements before encoding.
Node.js:
npm install @anb0s/plantuml-encoder
browser:
bower install @anb0s/plantuml-encoder
var plantumlEncoder = require('@anb0s/plantuml-encoder')
var encoded = plantumlEncoder.encode('A -> B: Hello')
console.log(encoded) // SrJGjLDmibBmICt9oGS0
var url = 'http://www.plantuml.com/plantuml/img/' + encoded
The URL can then be used to display the diagram:
var plantumlEncoder = require('@anb0s/plantuml-encoder')
var plain = plantumlEncoder.decode('SrJGjLDmibBmICt9oGS0')
console.log(plain) // A -> B: Hello
MIT