New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

obtool

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

obtool

Front-end build tool, based on webpack, faced to react, with hot reload

latest
npmnpm
Version
0.1.2
Version published
Maintainers
1
Created
Source

obtool

Front-end build tool, based on webpack, faced to react, with hot reload.

Usage

Step 1

$ npm install --save-dev obtool
$ npm install react react-dom

or

$ yarn add --dev obtool
$ yarn add react react-dom

Step 2

Edit your package.json, add scripts like this:

{
    "scripts": {
        "start": "obtool start",
        "build": "obtool build"
    },
}

Step 3

Create file public/index.html, src/index.js, src/App.js.

$ mkdir public src
$ touch public/index.html src/index.js src/App.js

Step 4

Copy this in your public/index.html.

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
</head>
<body>
    <div id="root"></div>
</body>
</html>

Copy this in your src/index.js.

import ReactDOM from 'react-dom'
import { AppContainer } from 'react-hot-loader'

import App from './App'

const render = Component => ReactDOM.render(
    <AppContainer>
        <Component />
    </AppContainer>,
    document.getElementById('root')
)

render(App)

if (module.hot) module.hot.accept('./App', () => render(App))

Copy this in your src/App.js.

import React from 'react'

class App extends React.Component {
    render() {
        return <div>Hello, World</div>
    }
}

export default App

Should I add init script?

Step 5

Finally, let's run npm start or yarn start.

Inspired By

  • create-react-app
  • roadhog
  • vue-cli
  • poi
  • react-boilerplate

FAQs

Package last updated on 28 Jul 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts