redux-devtools
Advanced tools
Comparing version 2.1.3 to 3.0.0-alpha
@@ -211,2 +211,3 @@ 'use strict'; | ||
function unliftStore(liftedStore, reducer) { | ||
var lastDefinedState = undefined; | ||
return _extends({}, liftedStore, { | ||
@@ -219,3 +220,7 @@ devToolsStore: liftedStore, | ||
getState: function getState() { | ||
return unliftState(liftedStore.getState()); | ||
var state = unliftState(liftedStore.getState()); | ||
if (state !== undefined) { | ||
lastDefinedState = state; | ||
} | ||
return lastDefinedState; | ||
}, | ||
@@ -222,0 +227,0 @@ getReducer: function getReducer() { |
@@ -13,2 +13,6 @@ 'use strict'; | ||
exports.persistState = _interopRequire(_persistState); | ||
exports.persistState = _interopRequire(_persistState); | ||
var _connectMonitor = require('./connectMonitor'); | ||
exports.connectMonitor = _interopRequire(_connectMonitor); |
{ | ||
"name": "redux-devtools", | ||
"version": "2.1.3", | ||
"version": "3.0.0-alpha", | ||
"description": "Redux DevTools with hot reloading and time travel", | ||
@@ -56,4 +56,2 @@ "main": "lib/index.js", | ||
"dependencies": { | ||
"react-json-tree": "^0.1.9", | ||
"react-mixin": "^1.7.0", | ||
"react-redux": "^3.0.0", | ||
@@ -60,0 +58,0 @@ "redux": "^2.0.0 || ^3.0.0" |
@@ -16,5 +16,3 @@ Redux DevTools | ||
* With `persistState()` store enhancer, you can persist debug sessions across page reloads | ||
* To monitor a part of the state, you can set a `select` prop on the DevTools component: `<DevTools select={state => state.todos} store={store} monitor={LogMonitor} />` | ||
* Toggle visibility with Ctrl+H | ||
* To hide the devtools on load, set `visibleOnLoad` to false, e.g.: `<DevTools store={store} monitor={LogMonitor} visibleOnLoad={false} />` | ||
@@ -34,6 +32,8 @@ ### Installation | ||
import { compose, createStore, applyMiddleware } from 'redux'; | ||
// Redux DevTools store enhancers | ||
import { devTools, persistState } from 'redux-devtools'; | ||
// React components for Redux DevTools | ||
import { DevTools, DebugPanel, LogMonitor } from 'redux-devtools/lib/react'; | ||
// A monitor component for Redux DevTools | ||
import LogMonitor from 'redux-devtools-log-monitor'; | ||
``` | ||
@@ -47,4 +47,6 @@ | ||
applyMiddleware(m1, m2, m3), // any Redux middleware, e.g. redux-thunk | ||
// Provides support for DevTools: | ||
devTools(), | ||
// Lets you write ?debug_session=<name> in address bar to persist debug sessions | ||
@@ -57,3 +59,3 @@ persistState(window.location.href.match(/[?&]debug_session=([^&]+)\b/)) | ||
Finally, include the `DevTools` in your page. You may pass either `LogMonitor` (the default one) or any of the custom monitors described below. For convenience, you can use `DebugPanel` to dock `DevTools` to some part of the screen, but you can put it also somewhere else in the component tree. | ||
Finally, include the `DevTools` in your page. You may pass either `LogMonitor` (the default one) or any of the custom monitors described below. | ||
@@ -66,7 +68,6 @@ ```js | ||
<Provider store={store}> | ||
{() => <CounterApp />} | ||
<CounterApp /> | ||
</Provider> | ||
<DebugPanel top right bottom> | ||
<DevTools store={store} monitor={LogMonitor} /> | ||
</DebugPanel> | ||
<LogMonitor store={store.devToolsStore} /> | ||
</div> | ||
@@ -73,0 +74,0 @@ ); |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
3
0
132
21948
14
347
1
1
- Removedreact-json-tree@^0.1.9
- Removedreact-mixin@^1.7.0
- Removedbabel-runtime@5.8.38(transitive)
- Removedcore-js@1.2.7(transitive)
- Removedobject-assign@2.1.1(transitive)
- Removedreact@18.3.1(transitive)
- Removedreact-json-tree@0.1.9(transitive)
- Removedreact-mixin@1.7.0(transitive)
- Removedsmart-mixin@1.2.1(transitive)