Skip to content

is not supported resolving ES modules #207

Open
@dingshaohua-com

Description

when i us remote at main.js

import remote from '@electron/remote/main';
console.log(111, remote);

i got like this:

App threw an error during load
Error [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import '/electron-demo/node_modules/@electron/remote/main' is not supported resolving ES modules imported from /electron-demo/src/index.js
Did you mean to import "@electron/remote/main/index.js"?

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions