vega-embed Bower npm

Publish Vega visualizations as embedded web components with interactive parameters.


The vega-embed module provides advanced support for embedding interactive Vega views into web pages. The primary features include:

  • Load Vega specs from source text, parsed JSON, or URLs.
  • Add action links such as “View Source” and “Open in Vega Editor”.
  • Parameterize visualizations with auto-generated dynamic query widgets.

This last feature provides a powerful and convenient way to interact with a visualization by adding interactive widgets such as sliders, text fields, dropdown menus, and radio boxes. For Vega specifications without interactive signals defined, vega-embed provides rewriting rules for injecting interactivity into an existing spec.

For more, see the documentation on the Vega wiki.

For examples of vega-embed in action, take a look at the “Parameterized” specs in the Vega Editor, including the interactive job voyager and configurable force layout.

Build Process

To build vega-embed.js and view the test examples, you must have npm installed.

  1. Run npm install in the vega-embed folder to install dependencies.
  2. Run npm run build. This will invoke browserify to bundle the source files into vega-embed.js, and then uglify-js to create the minified vega-embed.min.js.
  3. Run a local webserver (e.g., python -m SimpleHTTPServer 8000) in the vega-embed folder and then point your web browser at the test directory (e.g., http://localhost:8000/test/).

Related Repositories



Publish Vega visualizations as embedded web components with interactive parameters. ...

Top Contributors

jheer domoritz arvind


-   v2.2.0 zip tar
-   v2.1.0 zip tar
-   v2.0.0 zip tar
-   v1.0.9 zip tar
-   v1.0.8 zip tar
-   v1.0.7 zip tar
-   v1.0.6 zip tar
-   v1.0.5 zip tar
-   v1.0.4 zip tar
-   v1.0.2 zip tar
-   v1.0.1 zip tar
-   v1.0.0 zip tar