Customize @jupyterlab module

I want to slightly modify @jupyterlab/filebrowser for an extension. I Git cloned @jupyterlab/filebrowser, published the cloned module, and “npm install …” it in my extension environment as @jws4399/filebrowser. My code is compiling without error, but when I go to Jupyterlab, the extension does not activate and I get a JS error message “Plugin ‘jupyterlab_s3_browser:drive’ failed to activate.” AND “Error: No provider for: @jws4399/filebrowser:IFileBrowserFactory.” Let me know if you guys have any ideas

A quick thought on that specific error: an extension that provides the file browser features needs to export exactly one plugin that provides the factory token, and it needs to be exactly the token provided by the upstream, e.g.

import {IFileBrowserFactory} from `@jupyterlab/filebrowser`

Otherwise, other (core) plugins will not be able to find it.

More broadly: doing a fork this way is going to be rather fragile over time. You may want to investigate a lighter-touch, composite approach, a la jupyterlab-filesystem-access that has a much smaller API interface.

Okay, thanks for responding!