Error: no loaders are configured while creating RenderingEngine object

Describe Your Question

I am trying to create an object of RenderingEngine so that I can use it to display custom rectangles on the DICOM images, however, I get the following errors after creating the object.

This is what the code looks like:

import RenderingEngine from '../../../node_modules/@cornerstonejs/core/src/RenderingEngine';

const renderingEngineId = "my-engine";
const renderingEngine = new RenderingEngine(renderingEngineId);

Why do I need loaders? Could be related to the location where I am creating the object (Currently inside a file in extensions folder-I created my own extension following the documentation) or related to RenderingEngine import.

don’t import rendering engine like that
look at our examples to see how you can render basic viewport