# ipreact

> connect data-actions of preact-components via immutablejs

Latest version **0.2.3** (published 2019-05-11) · MIT license · 0 weekly downloads

## Install

```sh
npm install ipreact
pnpm add ipreact
yarn add ipreact
bun add ipreact
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.3 |
| Published | 2019-05-11 |
| First published | 2018-03-05 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 17.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | shy2850 |
| Maintainers | shy2850 |
| Keywords | preact, immutablejs, f2e-server, f2e-preact-app |

## Links

- npm: https://www.npmjs.com/package/ipreact
- Repository: https://github.com/shy2850/ipreact
- Homepage: https://github.com/shy2850/ipreact#readme
- Issues: https://github.com/shy2850/ipreact/issues
- npm.io page: https://npm.io/package/ipreact

## Dependencies (1)

- [preact](https://npm.io/package/preact.md) ^8.3.1

## Alternatives

- [@lexical/table](https://npm.io/package/@lexical/table.md) — 3.0M weekly downloads
- [mantine-datatable](https://npm.io/package/mantine-datatable.md) — 98.2K weekly downloads
- [react-native-collapsible-tab-view](https://npm.io/package/react-native-collapsible-tab-view.md) — 70.6K weekly downloads
- [@handsontable/vue3](https://npm.io/package/@handsontable/vue3.md) — 16.1K weekly downloads
- [vuewordcloud](https://npm.io/package/vuewordcloud.md) — 7.2K weekly downloads

## Recent versions

- 0.2.3 (latest) — 2019-05-11
- 0.2.2 — 2019-01-31
- 0.2.0 — 2018-10-18
- 0.1.8 — 2018-06-12
- 0.1.7 — 2018-04-16
- 0.1.6 — 2018-03-08
- 0.1.5 — 2018-03-07
- 0.1.4 — 2018-03-07
- 0.1.3 — 2018-03-05
- 0.1.2 — 2018-03-05
- 0.1.1 — 2018-03-05
- 0.1.0 — 2018-03-05

## README

# IPreact
connect data-actions of preact-components

## Install
```
npm i ipreact
```

## Usage
```tsx
import IPreact from '../src/ipreact'
import { h, Component, render } from 'preact'
const { connect, dispatch, getState } = IPreact()({
    name: 'world'
})

const AppComponent = ({ words }) => <h2>{words}</h2>
const App = connect(() => ({
    words: `hello ${getState().name}!`
}))(AppComponent)

let i = 0
setInterval(function () {
    const list = ['prect', 'immutable', 'world', 'ipreact']
     i = (i + 1) % list.length
    dispatch(state => ({name: list[i]}))
}, 1000)
```
![hello world](./helloworld.gif)

---
_Source: https://npm.io/package/ipreact · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
