# redux-tuner

> Redux tuning

Latest version **0.0.6** (published 2019-09-11) · MIT license · 0 weekly downloads

## Install

```sh
npm install redux-tuner
pnpm add redux-tuner
yarn add redux-tuner
bun add redux-tuner
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.6 |
| Published | 2019-09-11 |
| First published | 2019-08-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 179.7 KB |
| Known vulnerabilities | 0 (+2 in 2 direct dependencies) |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Parham Zare |
| Maintainers | parhamzare |

## Links

- npm: https://www.npmjs.com/package/redux-tuner
- Repository: https://github.com/ParhamZare/redux-tuner
- Homepage: https://github.com/ParhamZare/redux-tuner#readme
- Issues: https://github.com/ParhamZare/redux-tuner/issues
- npm.io page: https://npm.io/package/redux-tuner

## Dependencies (3)

- [uuid](https://npm.io/package/uuid.md) ^3.3.3
- [dexie](https://npm.io/package/dexie.md) ^2.0.4
- [react](https://npm.io/package/react.md) ^16.9.0

## Recent versions

- 0.0.6 (latest) — 2019-09-11
- 0.0.5 — 2019-09-11
- 0.0.4 — 2019-09-05
- 0.0.3 — 2019-09-05
- 0.0.2 — 2019-08-31
- 0.0.1 — 2019-08-30

## README

# redux-tuning

![architecture text](https://github.com/ParhamZare/redux-tuner/raw/master/architecture.png)

Improve speed and add offline support for React&Redux Application with two-step

I think "Redux" is the best thing for javascript application It helps you write applications that behave consistently, run in different environments like ("Server" , " Mobile app", " WebApp").
when we dispatch some action in "Redux". "Redux" saves your application state and you can access your state with one container called "React-redux".

But I had one issue on mobile application and huge web application
when data is a huge and your app start to slow because all state stored in "Ram" .
 I started to write one module as "Redux-tuner" module. when I dispatch one action I wrote one middleware to store data in the disk and generate one key and change data to key in redux. when I need access data I transform data from key to data and use in React component or in middleware and I wrote on service to rehydrate redux state to enable offline mode for the application.

![architecture text](https://github.com/ParhamZare/redux-tunner/blob/master/Flow.svg)

Online example
https://codesandbox.io/s/github/ParhamZare/pepper

**Usage**

How Install Package:

```
npm i redux-tuner
```

First:

```javascript

import {createStore, applyMiddleware} from 'redux'
import rootReducer from '../reducer';
import {customStore, runService} from "redux-tunner";

const store = createStore(customStore(rootReducer));

runService(store)

export default store


```

Second

```javascript

import React from 'react';
import {connect} from 'react-redux';
import {TransformComponent} from "redux-tunner";

export const Component = (props) => {
    return (
        <div>
          <h1>redux tunner</h1>
        </div>
    )
};

function mapStateToProps(state) {
    return {};
}

function dispatchToProps(dispatch) {
    return {
      
    }
}

export default connect(mapStateToProps, dispatchToProps)(TransformComponent(Component))

```

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