Skip to content

Fix @nodegui/nodegui phantom dependency #233

@matronator

Description

@matronator

After starting webpack, it throws errors in several places, saying TS2307: Cannot find module '@nodegui/nodegui' or its corresponding type declarations. I noticed that @nodegui/nodegui is not declared anywhere in package.json despite being used in multiple places across the source code.

My guess is that you're relying on @nodegui/nodegui being included as a dependency from the @nodegui/react-nodegui package, making it a phantom dependency, which should be avoided. This isn't a problem when using regular npm and yarn, but it breaks (at least for me it did) when using pnpm.

Please consider adding @nodegui/nodegui as a dependency in this project or specify it as a peer dependency in the react-nodegui package to make it work effortlessly with pnpm.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions