question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Consuming vtk as a library

See original GitHub issue

I’m working on a project where I want to use vtk.js as a library. I want to bundle my project using webpack (i.e. include the relevant parts of vtk.js in that bundle). Based on what was said here, I figured vtk.js was an ES6 library, so I’ve just been importing the relevant bits using lines like import vtk from 'vtk.js/Sources/vtk';. However, I recently had some problems, as some of the test tooling I’m using does not support some of the ES7 features introduced here: https://github.com/Kitware/vtk-js/commit/27ad20500482e718371f477ff1ce22f9debf87d2

How should I consume vtk.js to avoid such problems?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
doczoidbergcommented, Feb 27, 2018

yes that is possible and I do it right now, but of course it isn’t as comfortable for development because no code completion etc.

1reaction
vidartfcommented, Feb 23, 2018

Thanks for the quick reply! That link seems like a good resource.

Do you use babel, or just modern enough runtime to not need transpilling?

I’m using typescript, and I’m having an issue with karma-typescript. With those resources, I’ll have a go at seeing if I can make it work (I’ll post the solution if I find one).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using vtk.js as an ES dependency - Kitware, Inc.
This guide illustrates how to consume vtk.js as an ES dependency. ... There are several ways to start a new vtk.js project.
Read more >
VTK/Java Wrapping - KitwarePublic
First, two checkboxes toggle VTK's garbage collection and the debug mode. Since VTK is a C++ library, it has its own mechanism for...
Read more >
Key Concepts — SMTK: Simulation Modeling Tool Kit, v1.0
It is used as a key so that each resource can own multiple geometry provider objects as needed, while providing type-safe access to...
Read more >
Documentation/dev/build.md · master - VTK - GitLab
A full-featured build of VTK depends on several open source tools and libraries such as Python, Qt, CGNS, HDF5, etc.
Read more >
Scientific Data Analysis and Visualization with VTK ... - YouTube
Scientific Data Analysis and Visualization with VTK and ParaView | SciPy 2015 | Cory Quammen. 10K views 7 years ago.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found