Git Product home page Git Product logo

rishichawda / minimal-react-boilerplate Goto Github PK

View Code? Open in Web Editor NEW
13.0 1.0 6.0 1.06 MB

A minimal react boilerplate with webpack 5 ๐Ÿ“ฆ, babel v7 :rocket: and SASS support. Linting, pre-commit hooks, snapshot and DOM testing, continuous integration and more already set up. :art:

License: MIT License

JavaScript 80.60% HTML 5.99% SCSS 1.38% TypeScript 12.03%
react webpack babel prettier-eslint sass boilerplate babel7 eslint prettier node-sass

minimal-react-boilerplate's Introduction

minimal-react-boilerplate

A minimal react boilerplate with webpack 5, babel v7 and SASS support.

  • Webpack 5 - All the good things from Webpack 5 including faster builds, smaller build sizes and more.

  • Babel 7

  • ESLint ( with prettier config ) - give the configuration a shot and thank me later. ๐Ÿ˜„

  • Husky - Pre-commit lint check for staged files to ensure ๐Ÿ’ฉ-code is never commited.

  • CSS and SASS support.

  • Easy and cleaner imports with babel module resolver.

For example, if you have a directory structure like this:

src
-- components
-- config
---- secret-config.js
-- pages
---- home
------ index.js

You can import secret-config.js in index.js as :

import config from "config/secret-config.js";
  • Environment files - environment variable imports are already configured and added! Just create development.env and production.env ( inside config directory ) with your environment variables and start using them in your app! ๐ŸŽ‰

  • Snapshots and DOM testing - Includes DOM testing with Jest and react-testing-library and also includes snapshot test examples with Jest. travis.yml is already included to run the tests on TravisCI.

Usage :

  1. Clone the repository via SSH :
$ git clone [email protected]:rishichawda/minimal-react-boilerplate.git

or HTTPS :

$ git clone https://github.com/rishichawda/minimal-react-boilerplate.git
$ cd minimal-react-boilerplate
$ npm install

Unfamiliar with git?

Simply click here to download the zip. Extract the .zip file and run the following commands inside the directory.

$ npm install
$ npm run start

To start the development server :

$ npm run start

To generate production build :

$ npm run build

minimal-react-boilerplate's People

Contributors

dependabot-preview[bot] avatar rishichawda avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

minimal-react-boilerplate'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.