npm install common-components
npm i -S common-components
`
In React component:
`javascript
import * as React from 'react'
import * as ReactDOM from 'react-dom'
import {Button} from 'common-components'class App extends Component {
render() {
return (
)
}
}
ReactDOM.render(
,
document.body
)
`
$3
Clone the repository and install dependencies.
`
npm install
`
$3
To start in development mode with HRM:
`
npm run start
`
To create bundle.js with index.html in dist/ folder:
`
npm run build
`
To release for publication in NPM:
`
npm run release
npm version patch
npm publish
`
To release minified production bundle:
`
npm run relmini
`
To release and install locally:
`
npm pack
> common-components-1.0.0.tgz
`
From project directory:
`
npm i /path/to/generated/common-components-1.0.0.tgz
``