Git Product home page Git Product logo

redux-universal's Introduction

The code is in experience mode & the docs need to be improved. If you see any problem with it, please correct me. Thank you.

Demo

http://45.79.94.169:3000 (still run on NODE_ENV=dev, so the performance would be slow)

Increase Dev Experience when coding on Client Side Render (not server)

Why?

  • Currently we rely on webpack-isomorphic-tools & webpack-isomorphic-tools will run every time we change code (it's take a lots of time - and sometime you need to restart the process to see the changes)
  • If you find any better solution, please notify me. Thank you

My Solution

  • Write tests for server rendering to make sure content will be rendered into html before sending to browser, see
tests/server-render.tests.js
  • We define webpack into 2 config files. 1 for client (dev.config) & 1 for universal (dev.universal.config (see in webpack) & production.universal.config - not implemented yet).
  • When coding, we start the client side render process to take all advantages on client render (speed & reloading)

Get Started

  • npm run dev-api
  • Start a new terminal and run: npm run dev (If you want to try server rendering, run: npm run dev-universal)

Features

Real world examples

  • An Blog site with server rendering for SEO Advantage (content will be rendered into Html before sending to client)

Tech

Commands

  • See latest at package.json

Issues

  • Nested Route (waiting for markdalgleish/redial#16)
  • Exit on test render on server (maybe find way to force stop webpack-isomorphic-tools)

TODO

  • Authentication middleware
  • Post Administration
  • Add More Testing: (http://redux.js.org/docs/recipes/WritingTests.html)
  • reselect
  • Try redux-saga
  • FlowType
  • Refactor webpack
  • SEO meta with react-helmet
  • Test Render on Server (for Blog Example) to make sure html is rendered on server
    • route to home
    • route to category page
    • route to tag page
    • route to post page
  • Config Continuous Delivery
  • Add Code Coverage with istanbul

Reference

Starter Kits

Libraries

Examples & Tutorials

redux-universal's People

Contributors

joehua87 avatar

Stargazers

Indrajith Bandara avatar Alexsey Ramzaev avatar Eugene Duboviy avatar Michael avatar Sunil Pai avatar

Watchers

James Cloos avatar Michael avatar  avatar

redux-universal's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.