Skip to content

single-spa/import-map-microfrontend-deps

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

import-map-microfrontend-deps

Simplified dependency management for microfrontends

Installation

npm i @single-spa/import-map-microfrontend-deps

Usage

import { buildImportMapDependencies } from "@single-spa/import-map-microfrontend-deps";
import { ImportMapMicrofrontendUtils } from "@single-spa/import-map-microfrontend-utils";

await buildImportMapDependencies({
  template: {
    imports: {
      react: "18.3.0",
      "react-dom": "18.3.0",
    },
    scopes: {},
  },
  outputFolder: "dist",
  utils: new ImportMapMicrofrontendUtils({
    baseOrigin: "https://cdn.example.com",
  }),
});