All Projects → Kornil → Simple React App

Kornil / Simple React App

Licence: mit
Simple base app using react, react-router v4, hot-reload & sass.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Simple React App

React Pages Boilerplate
Deliver react + react-router application to gh-pages
Stars: ✭ 134 (-49.05%)
Mutual labels:  eslint, boilerplate, jest, enzyme, hot-reload
React Redux Universal Boilerplate
An Universal ReactJS/Redux Boilerplate
Stars: ✭ 165 (-37.26%)
Mutual labels:  eslint, boilerplate, enzyme, hot-reload, sass
Js Stack Boilerplate
Final boilerplate code of the JavaScript Stack from Scratch tutorial –
Stars: ✭ 145 (-44.87%)
Mutual labels:  eslint, yarn, boilerplate, jest
React-Redux-Enterprise
A React-Redux boilerplate for enterprise/large scaled web applications
Stars: ✭ 77 (-70.72%)
Mutual labels:  eslint, enzyme, jest, react-router-v4
Iceberg
Front-End Boilerplate built with React + Babel + Webpack + SASS
Stars: ✭ 144 (-45.25%)
Mutual labels:  eslint, boilerplate, jest, sass
coconat
🍥 StarterKit Builder for rocket-speed App creation on 🚀 React 17 + 📙 Redux 4 + 🚠 Router 5 + 📪 Webpack 5 + 🎳 Babel 7 + 📜 TypeScript 4 + 🚔 Linters 23 + 🔥 HMR 3
Stars: ✭ 95 (-63.88%)
Mutual labels:  yarn, enzyme, jest, react-router-v4
Reeakt
A modern React boilerplate to awesome web applications
Stars: ✭ 116 (-55.89%)
Mutual labels:  eslint, jest, enzyme
Static Site Boilerplate
A better workflow for building modern static websites.
Stars: ✭ 1,633 (+520.91%)
Mutual labels:  eslint, boilerplate, sass
Modern Monorepo Boilerplate
Modern Monorepo Boilerplate with Lerna, TypeScript, React/CRA, HMR, Jest, ESLint/TypeScript.
Stars: ✭ 127 (-51.71%)
Mutual labels:  eslint, jest, hot-reload
Simple Universal React Redux
The simplest possible Async Universal React & Redux Boilerplate app, that works on both Mac and Windows
Stars: ✭ 58 (-77.95%)
Mutual labels:  eslint, sass, react-router-v4
Instapack
All-in-one TypeScript and Sass compiler for web applications! 📦 🚀
Stars: ✭ 131 (-50.19%)
Mutual labels:  eslint, hot-reload, sass
react16-seed-with-apollo-graphql-scss-router4-ssr-tests-eslint-prettier-docker-webpack3-hot
Seed to create your own project using React with Apollo GraphQL client
Stars: ✭ 19 (-92.78%)
Mutual labels:  eslint, jest, hot-reload
Node Flowtype Boilerplate
This boilerplate repository is outdated and no longer maintained. Instead, I strongly recommend to use TypeScript.
Stars: ✭ 104 (-60.46%)
Mutual labels:  eslint, boilerplate, jest
Hapi Starter Kit
Hapi.js based REST boilerplate which uses latest ES7/ES8 features (async/await) with code coverage and follows best pratices
Stars: ✭ 103 (-60.84%)
Mutual labels:  eslint, yarn, boilerplate
Vue Admin Element
(Vue2 演示项目)物业后台管理系统 - ElementUI ( 基本结构已完成, 剩下的就是具体业务开发; 如有疑问请留言 )
Stars: ✭ 73 (-72.24%)
Mutual labels:  eslint, yarn, sass
100 Days Of Code Frontend
Curriculum for learning front-end development during #100DaysOfCode.
Stars: ✭ 2,419 (+819.77%)
Mutual labels:  eslint, jest, sass
Front End Guide
📚 Study guide and introduction to the modern front end stack.
Stars: ✭ 14,073 (+5250.95%)
Mutual labels:  eslint, yarn, jest
Html Sass Babel Webpack Boilerplate
Webpack 4 + Babel + ES6 + SASS + HTML Modules + Livereload
Stars: ✭ 35 (-86.69%)
Mutual labels:  eslint, boilerplate, sass
Node Typescript Boilerplate
Minimalistic project template to jump start a Node.js back-end application in TypeScript. ESLint, Jest and type definitions included.
Stars: ✭ 1,061 (+303.42%)
Mutual labels:  eslint, boilerplate, jest
Express Webpack React Redux Typescript Boilerplate
🎉 A full-stack boilerplate that using express with webpack, react and typescirpt!
Stars: ✭ 156 (-40.68%)
Mutual labels:  eslint, yarn, jest

simple-react-app

forthebadge

But you still get it.

Simple base app with react, react-router v4, hot-reload & sass.

npm i -g simple-react-app to install the package.

simple-react-app folderName to start the boilerplate into folderName folder.

Or if you're using [email protected] or above, you can simply run npx simple-react-app folderName, without the need to install the package globally.

What is this

This is a base project that you can use to jumpstart your react apps, it works similarly to create-react-app, just install the package globally and use it to create as many projects as you want (check How to install for detailed instructions). It includes the last react spec as of today 01/03/2018, and uses react-router v4 to handle routes. Style is handled by sass/scss, Bundle is generated with webpack 4. NB: this is just front end, you can use whatever backend language you are most comfortable with.

How to install

You can use both npm or yarn, the version I used to create this project are:

$ node -v ; npm -v ; yarn -v
v8.8.1
5.4.2
1.2.1

If you just freshly installed yarn/npm you are good to go, else you might need to upgrade, for npm I use n

npm install -g n

to install it and after that select at least the stable version (what I used).

n stable

and now you have the latest stable version of node&npm.

npm i -g simple-react-app to install this package globally, from there you will be able to jumpstart as many boilerplates as you wish.

simple-react-app folderName to create a react boilerplate on the folderName folder. By default all dependencies are already installed, just cd folderName and start hacking.

yarn start/npm start to start dev server with hot reload, it's live on localhost:3000.

yarn run build/npm run build to build prod bundle, it includes both treeshaking and uglify to optimize the code as much as possible.

yarn test/npm test run the tests with Jest and Enzyme, by default the test included only check for the correct render of base components & routes, all are passing.

Project structure

The boilerplate structure and files are the same as this repo minus the bin folder, everything else is exactly the same.

*root*
|
├── */src/*
│   ├── */assets/* where images and stuff are stored
│   ├── */containers/* react-router jsx pages
│   ├── *App.jsx* main layout
│   ├── *Routes.jsx* front-end routes
│   ├── *index.html* entry point
│   ├── *index.jsx* javascript entry point
│   ├── *style.scss* styling
│   └── */tests/* contains test environment (Jest + Enzyme)
│       ├── */__mock__/* contains setup to provide a valid path for imports
│       ├── */_tests__/* the actual tests
│       └── *setup.js* setup for enzyme for react 16
├── *package.json* the whole package.json with every dependency and script, nothing is kept hidden
├── *.eslintrc* eslint config
├── *.babelrc* babel config (polyfills)
├── *webpack.config.js* webpack config, it has a dev and prod environment
└── *README.md* this file

Tests

The testing environment is written in Jest and Enzyme. The included tests are very basic and only check the proper render of base components + routes, there are no snapshot tests, I did not feel they were needed being the components really basic, at the first change they would need to be updated, imho setting the wrong approach of "hey tests are broken, let's regenerate snapshots again". While still basic, the default tests are easy to manage and expand, providing a smoother curve into testing with JavaScript and React.

Eslint

This project uses AirBnB Javascript specs so you can write error-free react and javasctipt code, if you use Visual Studio Code, you can install eslint from the extension tab to activate this function, other editors just google name of the editor + eslint you will find how to enable it for your editor.

How to contribute

I wrote a small guide on how to contribute and the common etiquette to follow.

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].