Skip to content
This repository was archived by the owner on Dec 18, 2024. It is now read-only.
This repository was archived by the owner on Dec 18, 2024. It is now read-only.

[module-federation-runtime] Warnings importing as a CommonJs module #13

@lij20

Description

@lij20

I have a React application using Node 12, so I can not use ES modules. When I try to import the module-federation-runtime package as a Common JS module like this:

import { registerRemotes, findModule } from "module-federation-runtime/dist/node";

I get these warnings:

Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

and

Error: Can’t resolve ‘module’ in ‘.../packages/widgets/node_modules/module-federation-runtime/dist/node

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions