Have ideas to improve npm?Join in the discussion! »

    npu

    1.2.2 • Public • Published

    Create React apps fast with no Webpack

    Npm Version Month Downloads Npm Licence

    Features

    • Create React examples for your packages in two steps

    Installation

    npm install -g npu
    

    Install peer dependencies in project root:

    npm install react react-dom
    

    Example

    ./lib/index.js

    const MyComponent = () => (
      <div>My Component</div>
    )
    
    module.exports = MyComponent
    

    ./npu.config.js

    module.exports = {
      app: './example/App.js'
    }

    ./example/App.js

    import React from 'react'
    import MyComponent from '../lib'
     
    export default class App extends React.Component {
      render() {
        return (
          <div>
            Example:
            <MyComponent />
          </div>
        )
      }
    }

    That's it!

    Now you can make npu -d to run example in dev mode, or npu -o ./build to build app.

    TODO

    • Deployment to surge.sh

    Install

    npm i npu

    DownloadsWeekly Downloads

    37

    Version

    1.2.2

    License

    MIT

    Last publish

    Collaborators

    • avatar