Miss any of our Open RFC calls?Watch the recordings here! »

@mocoding/react-app

1.0.2 • Public • Published

@mocoding/react-app

Bootstrap and Build System for React Web Application. Batteries included.

Getting started

Create package.json with the following content:

{
  "name": "example",  
  "devDependencies": {
    "@mocoding/react-app": "*",    
  },  
  "scripts": {
    "start": "moapp serve",    
    "build": "moapp build -p"
  },
  "eslintConfig": {
    "extends": "@mocoding/eslint-config"
  },
  "prettier": "@mocoding/eslint-config/prettier"
}

Add index.tsx to the root.

import * as React from "react";
 
export class App extends React.Component {
  public render(): JSX.Element {
    return <div>Hello World</div>;
  }
}

Add tsconfig.json

{
  "extends": "@mocoding/react-app-common/tsconfig.base.json",
  "compilerOptions": {
    "baseUrl": "."
  }
}

Test the code:

# Restore dependencies 
> yarn
# Test application in development with HMR 
> yarn start
# Build application for production 
> yarn build

Details

Check project github for more documentation about this module.

Keywords

none

Install

npm i @mocoding/react-app

DownloadsWeekly Downloads

0

Version

1.0.2

License

MIT

Unpacked Size

52.6 kB

Total Files

74

Last publish

Collaborators

  • avatar