Coder Social home page Coder Social logo

sragss / react-bare-minimum Goto Github PK

View Code? Open in Web Editor NEW

This project forked from krasimir/react-bare-minimum

0.0 0.0 0.0 241 KB

A bare minimum setup to work with react. Compiling and bundling, nothing else.

License: MIT License

JavaScript 99.96% HTML 0.04%

react-bare-minimum's Introduction

React Bare Minimum

A bare minimum setup to work with react. Compiling and bundling, nothing else.

  • It compiles ES6 code containing JSX syntax
  • It bundles your code to a single JavaScript file
  • There is a watcher running above two when you change a file
  • That's it all folks

I'm sick of copy-pasting files and configuring when writing blog posts related to React. I just wanted something small which I download and start using.


How to use it

Just download the package. I don't see much of value in using npm i react-bare-minimum because the idea is to use it as a working directory.

Once you have the files:

  • Make sure that you have a .babelrc file with content
    {
      "presets": [
        "@babel/preset-react",
        "@babel/preset-env"
      ]
    }
    
  • Run npm i (or yarn install).
  • npm run build (yarn build) for building the project once
  • npm run watch (yarn watch) for run the watcher

When the build finishes check out the public folder. There is an index.html file and your bundled app.js.

Dependencies

  • babel-core
  • babel-preset-es2015
  • babel-preset-react
  • babelify
  • browserify
  • react
  • react-dom
  • watchify

Misc

The bare minimum to work with React article

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.