merge: components package preparation, replace components on learn-example (#835)
* [#812,package][xl]: package preparation, replace components on learn-example * [#812,package][xs]: upgrade portaljs/components version on learn-example * [package][xs]: add deboundebinput back to lean-example
This commit is contained in:
@@ -1,32 +1,29 @@
|
||||
# `components` package
|
||||
# PortalJS React Components
|
||||
|
||||
**See live:** https://storybook.portaljs.org
|
||||
**Storybook:** https://storybook.portaljs.org
|
||||
**Docs**: https://portaljs.org/docs
|
||||
|
||||
## Usage
|
||||
|
||||
To install this package on your project:
|
||||
|
||||
```bash
|
||||
npm i @portaljs/components
|
||||
```
|
||||
|
||||
> Note: React 18 is required.
|
||||
|
||||
You'll also have to import the styles CSS file in your project:
|
||||
|
||||
```ts
|
||||
// E.g.: Next.js => pages/_app.tsx
|
||||
import '@portaljs/components/styles.css'
|
||||
```
|
||||
|
||||
## Dev
|
||||
|
||||
Use Storybook to work on components by running:
|
||||
|
||||
```bash
|
||||
yarn storybook
|
||||
npm run storybook
|
||||
```
|
||||
|
||||
## Build
|
||||
|
||||
To build this project, run:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
## Install
|
||||
|
||||
TODO: command to install the package
|
||||
|
||||
### Next.js
|
||||
|
||||
Add this line at the start of `_app.tsx`:
|
||||
|
||||
```ts
|
||||
// pages/_app.tsx
|
||||
import "dist/styles.css";
|
||||
```
|
||||
Reference in New Issue
Block a user