Giter Site home page Giter Site logo

2017-typescript-react's Introduction

Falieson's 2017 Typescript React Redux - Universally

A starter kit for universal react applications with typescript.

styled with prettier TypeScript nps friendly Commitizen friendly

About

This starter kit is based off react-universally which provides

all the build tooling and configuration you need to kick off your next universal React project,
whilst containing a minimal "project" set up allowing you to make your own architecture decisions (Redux/MobX etc).

Then, I went ahead added my architecture decisions and preferences. I'm trying to organize commits so you can rebase and drop any commits starting w/ "ESLINT - " and get back to the base provided by react-universally

NOTICE: Please read this important issue about the behaviour of this project when using react-async-component, which is by default bundled with it.

Commands - READ THIS

* nps commit            : Creates a commit, don't use `git commit -m ...`
* nps precommit         : Use series.nps('precommit.a', .'precommit.z')
* nps                   : Starts the development server
* nps launch.prod       : Starts the production server
* nps build             : Starts the build process

Features - Separated by Repo

falieson/2017-typescript-react (this one)

  • ๐ŸŽฎ nps node-package-scripts removes the limitation of package.json enabling JS & //comments . Modify /package-scripts.js and use nps <command> instead of npm run <command>.
  • ๐Ÿ™Œ commitizen to help us generate beautifully formatted and consistent commit messages.
  • ๐Ÿ˜น cz-emoji is a plugin for commitizen that adds emoji to the commit template.
  • ๐ŸŽถ eslint preferences, @falieson 's preferences based on @kentcdodds .
  • ๐Ÿ”จ refactor 'shared' => 'src' (per ctrlplusb/react-universally#521)
  • ๐Ÿ”จ refactor 'shared/actions' & 'shared/reducers' => 'shared/redux/...' .
  • ๐Ÿ”จ refactor 'src/components/demoApp/' => 'src/app' & 'src/components/HTML/index' => 'src/utils/renderHtml'

from falieson/react-universally--typescript/features/redux-opinionated

Falieson/react-universally--typescript/feature/redux-opinionated

  • ๐Ÿ’ฐ redux as the state manager.
  • ๐Ÿ”† redux-developer-tools chrome extension
  • ๐ŸŽถ typescript because Flow doesn't work as well, and we will get increasing returns as bugs are reduced while adding developers.
  • ๐ŸŽถ tslint like eslint but for typescript, @falieson 's preferences.

from react-universally

  • ๐Ÿ‘€ react as the view.
  • ๐Ÿ”€ react-router v4 as the router.
  • ๐Ÿš„ express server.
  • ๐ŸŽญ jest as the test framework.
  • ๐Ÿ’„ Combines prettier and Airbnb's ESlint configuration - performing code formatting on commit. Stop worrying about code style consistency.
  • ๐Ÿ–Œ Very basic CSS support - it's up to you to extend it with CSS Modules etc.
  • โœ‚๏ธ Code splitting - easily define code split points in your source using react-async-component.
  • ๐ŸŒ Server Side Rendering.
  • ๐Ÿ˜Ž Progressive Web Application ready, with offline support, via a Service Worker.
  • ๐Ÿ˜ Long term browser caching of assets with automated cache invalidation.
  • ๐Ÿ“ฆ All source is bundled using Webpack v3.
  • ๐Ÿš€ Full ES2017+ support - use the exact same JS syntax across the entire project. No more folder context switching! We also only use syntax that is stage-3 or later in the TC39 process.
  • ๐Ÿ”ง Centralised application configuration with helpers to avoid boilerplate in your code. Also has support for environment specific configuration files.
  • ๐Ÿ”ฅ Extreme live development - hot reloading of ALL changes to client/server source, with auto development server restarts when your application configuration changes. All this with a high level of error tolerance and verbose logging to the console.
  • โ›‘ SEO friendly - react-helmet provides control of the page title/meta/styles/scripts from within your components.
  • ๐Ÿค– Optimised Webpack builds via HappyPack and an auto generated Vendor DLL for smooth development experiences.
  • ๐Ÿƒ Tree-shaking, courtesy of Webpack.
  • ๐Ÿ‘ฎ Security on the express server using helmet and hpp.
  • ๐Ÿœ Asset bundling support. e.g. images/fonts.
  • ๐ŸŽ› Preconfigured to support development and optimised production builds.
  • โค๏ธ Preconfigured to deploy to now with a single command.

Getting started

git clone https://github.com/falieson/2017-typescript-react my-project
cd my-project
npm install
npm run dev

Now go make some changes to the Home component to see the tooling in action.

Docs

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.