@genesisx/nextjs-mfe

5.1.0 • Public • Published

Nextjs Module Federator App Generator

This PSInnersource accelerator allows a developer to quickly setup a Nextjs based module federated application setup, using turbo as monorepo workspace.

Setup & Run locally

Make sure you use nodejs >= 18.17.0

  1. In a blank directory , run below command to start using it

npx @genesisx/nextjs-mfe

  1. It will ask various inputs like workspace name, container application name, remote app(s) name

  2. Once setup, go inside the workspace directory (cd workspace) and build the project

npm run build

  1. Serve the application as :

npm run dev

  1. You can access the application on : http://localhost:3000

Code Access

Please refer the following repo

https://pscode.lioncloud.net/psinnersource/xt/micro-frontend/genesisx/nextjs-accelerator

Need More details

Please reach out to Devesh Kaushal, Lalit Negi

Publish to NPM

Step 1 : Build the package npm run build Step 2 : Go to dist directory Step 3 : Run below command

npm publish --access public

NPM Repo : https://www.npmjs.com/package/@genesisx/nextjs-mfe

Node version Support

Node Version >= 18.17.0

NPM Packages

  • next | 14.1.0
  • react | 18.2.0
  • turbo | 1.10.15
  • webpack | 5.80.0
  • zustand | 4.4.3
  • @module-federation/nextjs-mf | 8.1.10

Changelog / Releases

Ver. 5.0.0 (Latest)

  • spec file addition for the unit testing of each component of the plopfile generator.
  • Coverage reports are generated for every file covered each test run.

Run all spec files contained within the workspace: npm run test

Run specific test files: npm run test <fileName>.spec.js

Run all tests associated with a name or key word: npm run <name>

  • A major change through restructuring of the codebase to increase readibility.
  • Components of the plopfile generator broken down into functions, actions and prompts.
  • The plopfile has been reduced in length and all components are imported here for execution

Ver. 4.3.2

  • Added dynamic port mapping to keep track of all micro apps.
  • Test cases for provided for templated apps allowing unit tests to be run and built upon out of the box.

Ver. 4.2.2

  • included feature that allows users to append additional micro applications to existing workspaces

Ver. 3.0.0

  • Added support to minify and uglify the published version of code to npm

Ver. 2.0.0

  • Added support for state sharing between multi micro-apps using zustand

Ver. 1.0.0

  • NextJs-MFE: module federation interapp proxy generator with turboRepo workspace support

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 5.1.0
    1
    • latest

Version History

Package Sidebar

Install

npm i @genesisx/nextjs-mfe

Weekly Downloads

9

Version

5.1.0

License

PublicisSapient Internal , see LICENSE file

Unpacked Size

51.7 kB

Total Files

57

Last publish

Collaborators

  • varkisebi
  • devesh.kaushal
  • paribhasika
  • sophiacmcg
  • shashixt
  • vigneshpushkaranps
  • tolalitnegi
  • nareshbhatia
  • iamdavidjackson
  • genesisy
  • venkateshmishra
  • dreamzmaster
  • harshi14
  • areai51