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

@kieler/elk-cli

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

@kieler/elk-cli

A commandline wrapper for elkjs.

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
7
increased by133.33%
Maintainers
4
Weekly downloads
 
Created
Source

ELK-CLI

This is a simple wrapper around elkjs to enable its usage directly from the commandline. It can be supplied with a graph from a file or directly over standard input. The expected format is the elkj format. When passing it directly in the commandline, care must be taken to correctly escape all quotes in the JSON object. The layouted graph is written elkj format to standard output.

Installation

The elk cli tool can be installed using node:

> npm install -g @kieler/elk-cli

and then run as

> elk -f <inputfile>

You can also run it directly using npx

> npx @kieler/elk-cli -f <inputfile>

Usage

Layout a graph provided in a json file:

> elk -f examples/graph.json

Layout a graph directly as an argument:

> elk -g "{\"id\": \"root\"}"

When passing in the graph as a string directly make sure to escape all double quotes that are part of the JSON.

Generate SVGs

You can automatically generate a simple SVG of the laid out graph using the -s <output.svg> option. A css file for styling may be supplied using the -c <style.css> file. The examples folder contains an example style file.

Keywords

FAQs

Package last updated on 02 Feb 2024

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