Skip to content

Generate a sequence diagram from a diagram DSL file and output it as a png image with a given name.

Notifications You must be signed in to change notification settings

timesking/sequence-diagram-generator

 
 

Repository files navigation

Build Status Stories in Ready Sequence Diagram Generator

This project can be used to generate sequence diagrams from the command line after defining the diagram with a simple DSL. It's a node wrapper around js-sequence-diagrams, check this page for DSL syntax http://bramp.github.io/js-sequence-diagrams/

  • add Support for flowchart.js
  • distinguish flow or sequence with file extented name. look run-demo.sh
./generate-sequence-diagram.js -f sequence-diagram.sequence -o sequence-diagram.png
./generate-sequence-diagram.js -f flowchart-diagram.flow -o flow-diagram.png
  • Upgrade nightmare to 2.5.1 the latest with Electron

Requirements

node.js, npm, phantomjs, handlebars

Setting up project

Clone project from git repository

git clone https://github.com/schrepfler/sequence-diagram-generator.git

Fetch dependencies

npm install

Generating sequence diagrams

Edit the sequence-diagrams.txt (or make your own) file according to the diagram syntax and after running the following command you will find a png with your image.

./generate-sequence-diagram.js -f sequence-diagram.txt -o sequence-diagram.png

TODO

  • Add an API eg.
var generator = require('generate-sequence-diagrams');
generator.generate('my dsl text', function (data) { // data is the output image });
  • See if we can avoid having to modify the tpl after precompilation.
  • Full lines seem not to be rendered, check with nightmare team or phantom or js-sequence-diagram project
  • npm-ise and publish
  • Add proper image caption above and below the image with stylesheet
  • See if libs can be fetched as deps
  • Tests
    • On body
    • On image

About

Generate a sequence diagram from a diagram DSL file and output it as a png image with a given name.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 62.4%
  • HTML 31.3%
  • Shell 6.3%