@react-instastories/base
v1.0.7
Published
The next generation of React Stories Library.
Downloads
4,695
Maintainers
Readme
React Stories Library
The next generation of React Stories Library.

Shared documentation
How to use it with the shared library can be found here: Shared Development Readme
Features
- Zero dependency React library;
- Customizable Stories Content;
- Small library gzip-size;
- Fast implementation in exists React projects;
- Huge possibility of customization (External Components Integration, Presets).
How to use
npm install @react-instastories/baseYou can install all react-instastories libraries for fast setup:
npm install @react-instastories/base @react-instastories/external @react-instastories/presetsImport and create your first InstaStories component:
// file.tsx
import {
InstaStories,
Page,
Pages,
Preview,
Stories,
Story
} from "@react-instastories/base";
import "@react-instastories/base/index.css";
export function AppStories() {
return (
<InstaStories>
<Stories>
<Story>
<Preview>Preview Content For Story #1</Preview>
<Pages>
<Page>Page Content For Page #1 in Story #1</Page>
</Pages>
</Story>
</Stories>
</InstaStories>
);
}// any-component.tsx
import { AppStories } from "../path/to/file";
// ... any place for render the component ...
<AppStories />;Additional libraries
- @react-instastories/external
- @react-instastories/presets
How to use with oldest React?
Some functions may stop working when using the library with older versions of
react. Please note that the potentially minimum supported version ofreactandreact-domis 16.14.0.
If you need to use this library with lower versions of react/react-dom, you can add the following parameter in your project's package.json file:
"overrides": {
"@react-instastories/base": {
"react": "$react",
"react-dom": "$react-dom",
}
}or specify the required version of the libraries instead of $react and $react-dom (for example, if you are not using these libraries directly)
"overrides": {
"@react-instastories/base": {
"react": "~16.14.0",
"react-dom": "~16.14.0",
}
}Author
Maintained by Dmitry Britov
