Composes error

Hi,

When importing vtkVolumeController I get the error: 'composition is only allowed when selector is single: local class name not in “.sliderIcon, “sliderIcon” is weird” ’ from the VolumeController.module.css file. How do fix this?

Thanks in advance!

How do you consume vtk.js? Do you import it from source and use your build environment to bundle it inside your application?

If so, this issue is related to a missing/corrupted loader rule defined here.

I understand. However those lines that you have selected are already in that file… so what exactly do I need to change?

I don’t know, that depends on how you’ve setup your application build system and how you use those rules. Does that mean my initial assumption was correct?

Yes your assumption was right. I try to use the import for that, but because that does not work I retrieve it by doing: const vtkVolumeController = vtk.Interaction.UI.vtkVolumeController; and include <script type="text/javascript" src="https://unpkg.com/vtk.js"></script> in html. That works fine.

1 Like