Code Monkey home page Code Monkey logo

react-flux-bootstrap's Introduction

react-flux-bootstrap

This project was originally forked from https://github.com/darul75/web-react so massive thanks to darul75.

web-react NPM version Build Status Total views Join the chat at https://gitter.im/darul75/web-react

Another Webpack React Kit.

Why

Because there are many React starter kits but some are so specific and difficult to take in hands.

Idea was to take in hands following stack :

  • ES6 : and you will learn React with awesome ECM6 features.
  • Webpack : amazing bundler, still to learn so much about it.
  • React : choosed because I love idea of Virtual DOM.
  • Flux : flux and used implementation is Alt
  • EsLint: JS and JSX syntax validator.
  • Express: Version 4.
  • Mocha: Testing.

For a simple website with no server side it is really fine.

For a more complex website, an Express server is used but work is not finished.

  • Server side React rendering is ready and done through React-Router
  • Flux on server side has begin thanks to Iso and Alt feature to bootstrap your app with data.
  • Some API server routes are just given as example.
  • You can debug it on server side thanks to sourcemaps.
  • NEW FEATURE : hot reloading of you code on server side too (node), it will patch silently without restarting your node server.

On both client/server Fetch request handler is used (for example on server side)

Hope you will enjoy.

CODE, DEBUG in an isomorphic JS way !

Demo

https://react-web.herokuapp.com/

Try reload page, put wrong path, snapshot todo list...play, I will improve it later to show how it works.

How to use it

DEV ONLY CLIENT

Webpack with hot changes loading but no own server, enough for a single presentation page app by instance. Port: 8080

See changes at http://127.0.0.1:8080

npm run dev

DEV ONLY CLIENT/SERVER

Let's use your own NodeJS server.

Start webpack in background with hot changes loading and debug in both client/server sides.

npm run dev-server-client

Then start your node server which is an express one in this case that will be launched in ES6 thanks to Babel.

npm run dev-server

or with debug nodejs mode :

npm run dev-server-debug

See changes at http://127.0.0.1:3000

PRODUCTION

Build production bundle both client and server.

npm run build

Run production client/server React/Express website.

npm run start

See it at http://127.0.0.1:3000

STRUCTURE

.
├── /build/                     # Compiled output
├── /conf/                      # Webpack scripts + testing glue.
├── /dist/                      # Production compiled output
├── /node_modules/              # 3rd-party libraries and utilities
├── /app/                       # Source code of the client application
│   ├── /actions/               # Action creators that allow to trigger a dispatch to stores
│   ├── /components/            # React components
|       |── /__tests__/         # React components unit tests
│   ├── /stores/                # Stores contain the application state and logic
├── /server/                    # The source code of the server application
│   ├── /api/                   # REST API
│   ├── /routes/                # Express routes entries
│   ├── /server/                # Server-side startup script
│   ├── /utils/                 # Some specific, rendering...
└── package.json                # The list of 3rd party libraries and utilities

RELEASE

  • 1.0.2: webpack hot module store fixture
  • 1.0.1: connect stores wrapper + refactoring
  • 1.0.0: footer + demo tags
  • 0.0.9: demo production distribution + local webpack path + licence
  • 0.0.8: hot HMR server reloading + refactor server directories.
  • 0.0.7: testing available with mocha, scss/sass/css loaders fixes.
  • 0.0.6: full ES6 + start refactoring.
  • 0.0.5: debug mode for both client/server side
  • 0.0.4: starter kit

Metrics

NPM

License

The MIT License (MIT)

Copyright (c) 2015 Julien Valéry

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

react-flux-bootstrap's People

Contributors

andyshora avatar

Watchers

 avatar

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.