How to gracefully add outer denpendency in customize extension ?

Describe Your Question

I am trying to building a new extension+mode in OHIF v3 and I’m facing a dependency issue

i tried to edit package.json directly in my customize extension, it works good on some simple npm package.but for those more complicated,it dosen’t work.

Is there a more elegant way to add dependencies in ohif’s monorepo framework? like use any cli command to enable package manager to automatically analyze and install the required dependencies to the specified ohif extension/mode?

If it is convenient, please give a brief workflow for this problem

Any help appreciated!