Skip to content

Boilerplate for a server side rendered React Application using Mobx as state manager

Notifications You must be signed in to change notification settings

webfueler/react-mobx-ssr-boilerplate

Repository files navigation

React Mobx SSR (Server Side Rendered) Boilerplate

Hey developer 👋

This is a repository with an example of a base application that can scale, using Mobx as state manager.

Some considerations were done while creating this boilerplate:

  • using classes for modules (OOP) instead of functional programming (could be refactored, but this is personal preference)
  • Interface based implementation (easy to swap modules at any time, different modules between server and client side if required)
  • used InversifyJS for inversion of control
  • made a simple webpack configuration

Developing

Install dependencies:

npm i

Start developing:

npm run dev

Production build

npm run build

Production server

npm run start

To Do:

  • better styling (this is mainly showcasing architecture, not UI)
  • extract layout to file for better customization (index.ejs)
  • ability to set basename by http request headers (x-basename) - good for ssr micro-frontends
  • replace <Head> custom implementation with react-helmet

About

Boilerplate for a server side rendered React Application using Mobx as state manager

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published