Giter Site home page Giter Site logo

koshkarov / reactjs-grunt-configuration Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 90 KB

React Grunt ๐Ÿ— Configuration defines the build configuration for development/production of the React app. ๐Ÿ‘Œ

License: MIT License

JavaScript 90.79% CSS 1.04% HTML 8.18%

reactjs-grunt-configuration's Introduction

ReactJs Grunt build configuration

ReactJs Grunt build configuration is a small project to show the build process for ReatJs app using Grunt, Browserify, Babelify, etc. Sometimes it is required to integrate ReatJs app in to the existing build process using Grunt and without Webpack.

In this configuration were used the following Grunt tasks:

  • borwserify (with babelify) - builds a bundle and transpiles ES6/JSX to plain javascript.
  • uglify, htmlmin, cssmin - compress JavaScript, CSS, and HTML files respectively.
  • clean - removes files and folders.
  • concat - concatenates files (in this project CSS files)
  • template - interpolates template files with any data you provide and saves the result to another file.
  • copy - copies files.
  • watch - runs predefined tasks whenever watched file patterns are added, changed or deleted.
  • run - in this project runs Jest tests.

Installation & Unsage

For running you will need npm package. For the first use please run:

npm install

Development

grunt react_build_debug

directory ./client will be created with non-minified files.

Tests

Jest tests are configured for ReactJs app. To run tests using Grunt please execute:

grunt run:react_jest_tests

or NPM:

npm test

Production

You could build your project for production:

grunt react_build_release

directory ./client will be created with minified files.

reactjs-grunt-configuration's People

Contributors

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