import React, { Suspense, lazy } from 'react'; // @ts-ignore import ReactComponent from 'modern-js-provider/react-component'; import TestRemoteHook from './test-remote-hook'; import { loadRemote } from '@module-federation/runtime'; import LocalBtn from './components/ButtonOldAnt'; import WebpackPng from './webpack.png'; import WebpackSvg from './webpack.svg'; function DynamicRemoteButton() { // @ts-ignore ignore const Comp = React.lazy(async () => { //@ts-ignore const Button = await loadRemote('dynamic-remote/ButtonOldAnt'); console.log('BUTTON'); console.log(Button); return Button; }); console.log('loadManifestProvider'); return ( ); } const WebpackSvgRemote = lazy(() => import('remote1/WebpackSvg').then((m) => { return m; }), ); const WebpackPngRemote = lazy(() => import('remote1/WebpackPng')); const App = () => (

Manifest Basic Usage

check static remote

Test case Expected Actual
Test hook from remote localhost:3009
Page with custom remote hook. You must see text in red box below:
Custom hook from localhost:3009 works!
Loading remote component with PNG image from localhost:3009
(check publicPath fix in image-loader)
Loading remote component with SVG from localhost:3009
(check publicPath fix in url-loader)

check dynamic remote

Test case Expected Actual
Loading dynamic remote Button from localhost:3010
); export default App;