All Projects β†’ chikara-chan β†’ React Isomorphic Boilerplate

chikara-chan / React Isomorphic Boilerplate

Licence: mit
🌟 An universal React isomorphic boilerplate for building server-side render web app.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to React Isomorphic Boilerplate

Project Webcube
Continuously updated JS infrastructure for modern web dev
Stars: ✭ 141 (-78.41%)
Mutual labels:  webpack, eslint, babel, isomorphic, boilerplate, server-side-rendering
React App
Create React App with server-side code support
Stars: ✭ 614 (-5.97%)
Mutual labels:  webpack, babel, isomorphic, boilerplate, server-side-rendering
Js Stack Boilerplate
Final boilerplate code of the JavaScript Stack from Scratch tutorial –
Stars: ✭ 145 (-77.79%)
Mutual labels:  webpack, eslint, babel, boilerplate, server-side-rendering
Pwa
An opinionated progressive web app boilerplate
Stars: ✭ 353 (-45.94%)
Mutual labels:  webpack, eslint, babel, boilerplate
React Bolt
⚑ The most simple & robust boilerplate for your React projects.
Stars: ✭ 298 (-54.36%)
Mutual labels:  webpack, eslint, babel, boilerplate
Electron React Boilerplate
A Foundation for Scalable Cross-Platform Apps
Stars: ✭ 18,727 (+2767.84%)
Mutual labels:  webpack, eslint, babel, boilerplate
Express React Boilerplate
πŸš€πŸš€πŸš€ This is a tool that helps programmers create Express & React projects easily base on react-cool-starter.
Stars: ✭ 32 (-95.1%)
Mutual labels:  webpack, eslint, babel, boilerplate
Static Site Boilerplate
A better workflow for building modern static websites.
Stars: ✭ 1,633 (+150.08%)
Mutual labels:  webpack, eslint, babel, boilerplate
React Redux Auth0 Kit
Minimal starter boilerplate project with CRA, React, Redux, React Router and Auth0 authentication
Stars: ✭ 115 (-82.39%)
Mutual labels:  webpack, eslint, babel, boilerplate
React Pages Boilerplate
Deliver react + react-router application to gh-pages
Stars: ✭ 134 (-79.48%)
Mutual labels:  webpack, eslint, babel, boilerplate
Iceberg
Front-End Boilerplate built with React + Babel + Webpack + SASS
Stars: ✭ 144 (-77.95%)
Mutual labels:  webpack, eslint, babel, boilerplate
React Redux Saucepan
A minimal and universal react redux starter project. With hot reloading, linting and server-side rendering
Stars: ✭ 86 (-86.83%)
Mutual labels:  eslint, babel, boilerplate, server-side-rendering
Razzle Material Ui Styled Example
Razzle Material-UI example with Styled Components using Express with compression
Stars: ✭ 117 (-82.08%)
Mutual labels:  webpack, isomorphic, boilerplate, server-side-rendering
React Starter Kit
React, Redux, Webpack, Material UI, Boostrap 4, Code Splitting, HMR
Stars: ✭ 229 (-64.93%)
Mutual labels:  webpack, eslint, babel, boilerplate
React Redux Universal Boilerplate
An Universal ReactJS/Redux Boilerplate
Stars: ✭ 165 (-74.73%)
Mutual labels:  webpack, eslint, babel, boilerplate
Threejs Webpack Es6 Boilerplate
A basic boilerplate for a Three.js project compiled with Webpack and transpiled via Babel to enable using ES6 syntax.
Stars: ✭ 267 (-59.11%)
Mutual labels:  webpack, eslint, babel, boilerplate
Blog
Front-end tech thoughts and share-ppt
Stars: ✭ 288 (-55.9%)
Mutual labels:  webpack, babel, koa2
React Redux Sass Starter
Everything you need to get started with a basic React application
Stars: ✭ 293 (-55.13%)
Mutual labels:  webpack, eslint, babel
Ssr Sample
A minimum sample of Server-Side-Rendering, Single-Page-Application and Progressive Web App
Stars: ✭ 285 (-56.36%)
Mutual labels:  webpack, babel, server-side-rendering
Server Side Rendering
Interactive guide to server-side rendering with Webpack, React, React Transmit, CSS modules and more
Stars: ✭ 352 (-46.09%)
Mutual labels:  webpack, babel, server-side-rendering

React Isomorphic Boilerplate

An universal React isomorphic boilerplate for building server-side render web app.

dependencies Status devDependencies Status PRs Welcome npm

Introduction

This repository is an universal React isomorphic boilerplate for developer to quickly build a super fast and powerful web app that can be rendered both on the client and on the server using the most cutting-edge technology. Compared to others, this boilerplate has more pithily and more elegant configuration file based on environment variables, one for development, one for production. In addition, the directory structure is organized corresponding to mvc principle aim at the best practice.

Technology Stack

Getting Started

  • Require Node.js v6 or later.
  • npm install to install dependencies and devDependencies.
  • npm run dev to start up the development environment.
  • npm run build to compile and bundle the client and server files.
  • npm start to deploy the production server.

What's included

react-isomorphic-boilerplate/                // root directory
β”œβ”€β”€ build/                                   // webpack config directory
β”‚     β”œβ”€β”€ webpack.dev.config.js                 // config for webpack when run development bundle
β”‚     └── webpack.prod.config.js                // config for webpack when run production bundle
β”œβ”€β”€ client/                                  // client directory
β”‚     β”œβ”€β”€ about/                                // `about` module
β”‚     β”œβ”€β”€ common/                               // `common` module
β”‚     β”œβ”€β”€ home/                                 // `home` module
β”‚     β”œβ”€β”€ shared/                               // shared module
β”‚     β”œβ”€β”€ explore/                              // `explore` module
β”‚     β”œβ”€β”€ index.js                              // client entry file
β”‚     └── routes.js                             // client route config
β”œβ”€β”€ dist/                                    // bundle output directory
β”‚     β”œβ”€β”€ client/                               // the client side output directory
β”‚     └── server/                               // the server side output directory
β”œβ”€β”€ server/                                  // server directory
β”‚     β”œβ”€β”€ controllers/                          // controllers in server
β”‚     β”œβ”€β”€ middlewares/                          // custom middlewares in server
β”‚     β”œβ”€β”€ models/                               // models in server
β”‚     β”œβ”€β”€ routes/                               // routes in server
β”‚     β”œβ”€β”€ app.js                                // create koa instance in server
β”‚     β”œβ”€β”€ server.dev.js                         // entry file in development mode
β”‚     └── server.prod.js                        // entry file in production mode
β”œβ”€β”€ views/                                   // views directory
β”‚     β”œβ”€β”€ dev/                                  // output files generated by tpl in development mode
β”‚     β”œβ”€β”€ prod/                                 // output files generated by tpl in production mode
β”‚     └── tpl                                   // templates injected by html-webpack-plugin
β”œβ”€β”€ .editorconfig                            // uniform the text editor behavior
β”œβ”€β”€ .eslintignore                            // which paths should be omitted from linting
β”œβ”€β”€ .eslintrc.json                           // specific rules for eslint
β”œβ”€β”€ .gitattributes                           // uniform the new line perform behavior
β”œβ”€β”€ .gitignore                               // ignore the specific files when using git
β”œβ”€β”€ LICENSE                                  // license information
β”œβ”€β”€ package.json                             // npm entry file
β”œβ”€β”€ README.md                                // just what you see now
└── yarn.lock                                // lock file autogenerated by yarn

Why Isomorphic

SEO

An application that can only run in the client-side cannot serve HTML to crawlers, so it will have poor SEO by default. Web crawlers function by making a request to a web server and interpreting the result. but if the server returns a blank page, it’s not of much value. There are workarounds, but not without jumping through some hoops.

Performance

By the same token, if the server doesn’t render a full page of HTML but instead waits for client-side JavaScript to do so, users will experience a few critical seconds of blank page or loading spinner before seeing the content on the page. There are plenty of studies showing the drastic effect a slow site has on users, and thus revenue.

Maintainability

While the ideal case can lead to a nice, clean separation of concerns, inevitably some bits of application logic or view logic end up duplicated between client and server, often in different languages. Common examples are date and currency formatting, form validations, and routing logic. This makes maintenance a nightmare, especially for more complex apps.

Problem exists yet

FOUC

It happens when run in development mode. This is caused by deprecated using extract-text-webpack-plugin in development for getting a seamless hmr experience.(Why deprecated? See this Issue) If you are not an OCD, go ahead, ignore it.

Mismatch

It happens also when run in development mode. This is caused by when you update the react component code and reload the page, the markup generated mismatches that on server render. However, once you restart the server, the checksum will be valid. So it is harmless, ignore it also.

Links

http://www.jianshu.com/p/0ecd727107bb

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].