mps_ui_shared_components

1.0.6 • Public • Published

MyPath Shared Component Library

Module Federation shared components

Purpose

Some components can be used by the Educator applicatiosn and by the Student Application. These components belong in this library.

Components only used by the Educator application should be in mps.ui.educator-component-library Components only used by the Student Appication should be in the ux-component-library in the Student application

Requirements

Getting Started

Install dependancies

npm i

Run the application locally

npm start

Using the library

The mps.ui.shared-components is imported as a module federation remote

in webpack.config

plugins: [
    new ModuleFederationPlugin({
      name: "mps_ui_shared_components",
      filename: "remoteEntry.js",
      remotes: {
        "@imaginelearning/mps_ui_shared_components": "mps_ui_shared_components@http://localhost:3030/remoteEntry.js"
      },
      exposes: {
        "./FeatureFlagProvider": "./src/usefeatureflag/featureflagprovider",
        "./useFeatureFlag": "./src/usefeatureflag/usefeatureflag",
        "./useLocalStorage": "./src/uselocalstorage/uselocalstorage",
      }
    })
]

Components

Feature flags

a relative link

useLocalStorage

a relative link

Readme

Keywords

none

Package Sidebar

Install

npm i mps_ui_shared_components

Weekly Downloads

0

Version

1.0.6

License

UNLICENSED

Unpacked Size

41.7 kB

Total Files

27

Last publish

Collaborators

  • twigweb