mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2025-07-23 06:29:51 +03:00
Fix extension build
This commit is contained in:
parent
e6edc33b22
commit
8cdb8c3298
|
@ -1,7 +1,7 @@
|
||||||
import mapValues from 'lodash/mapValues';
|
import mapValues from 'lodash/mapValues';
|
||||||
import { Action } from 'redux';
|
import { Action } from 'redux';
|
||||||
import { LiftedState, PerformAction } from '@redux-devtools/instrument';
|
import { LiftedState, PerformAction } from '@redux-devtools/instrument';
|
||||||
import { LocalFilter } from '@redux-devtools/utils/lib/filters';
|
import { LocalFilter } from '@redux-devtools/utils';
|
||||||
|
|
||||||
export type FilterStateValue =
|
export type FilterStateValue =
|
||||||
| 'DO_NOT_FILTER'
|
| 'DO_NOT_FILTER'
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import jsan from 'jsan';
|
import jsan from 'jsan';
|
||||||
import seralizeImmutable from '@redux-devtools/serialize/lib/immutable/serialize';
|
import { immutableSerialize } from '@redux-devtools/serialize';
|
||||||
import {
|
import {
|
||||||
Config,
|
Config,
|
||||||
SerializeWithImmutable,
|
SerializeWithImmutable,
|
||||||
|
@ -44,7 +44,7 @@ export default function importState<S, A extends Action<unknown>>(
|
||||||
parse = (v) =>
|
parse = (v) =>
|
||||||
jsan.parse(
|
jsan.parse(
|
||||||
v,
|
v,
|
||||||
seralizeImmutable(
|
immutableSerialize(
|
||||||
serialize.immutable,
|
serialize.immutable,
|
||||||
serialize.refs,
|
serialize.refs,
|
||||||
serialize.replacer,
|
serialize.replacer,
|
||||||
|
|
|
@ -1,15 +1,14 @@
|
||||||
import jsan, { Options } from 'jsan';
|
import jsan, { Options } from 'jsan';
|
||||||
import throttle from 'lodash/throttle';
|
import throttle from 'lodash/throttle';
|
||||||
import serializeImmutable from '@redux-devtools/serialize/lib/immutable/serialize';
|
import { immutableSerialize } from '@redux-devtools/serialize';
|
||||||
import { getActionsArray } from '@redux-devtools/utils';
|
import { getActionsArray, getLocalFilter } from '@redux-devtools/utils';
|
||||||
import { getLocalFilter } from '@redux-devtools/utils/lib/filters';
|
|
||||||
import { isFiltered, PartialLiftedState } from './filters';
|
import { isFiltered, PartialLiftedState } from './filters';
|
||||||
import importState from './importState';
|
import importState from './importState';
|
||||||
import generateId from './generateInstanceId';
|
import generateId from './generateInstanceId';
|
||||||
import { Config } from '../../browser/extension/inject/pageScript';
|
import { Config } from '../../browser/extension/inject/pageScript';
|
||||||
import { Action } from 'redux';
|
import { Action } from 'redux';
|
||||||
import { LiftedState, PerformAction } from '@redux-devtools/instrument';
|
import { LiftedState, PerformAction } from '@redux-devtools/instrument';
|
||||||
import { LibConfig } from '@redux-devtools/app/lib/actions';
|
import { LibConfig } from '@redux-devtools/app';
|
||||||
import {
|
import {
|
||||||
ContentScriptToPageScriptMessage,
|
ContentScriptToPageScriptMessage,
|
||||||
ListenerMessage,
|
ListenerMessage,
|
||||||
|
@ -77,7 +76,7 @@ export function getSerializeParameter(config: Config) {
|
||||||
if (serialize) {
|
if (serialize) {
|
||||||
if (serialize === true) return { options: true };
|
if (serialize === true) return { options: true };
|
||||||
if (serialize.immutable) {
|
if (serialize.immutable) {
|
||||||
const immutableSerializer = serializeImmutable(
|
const immutableSerializer = immutableSerialize(
|
||||||
serialize.immutable,
|
serialize.immutable,
|
||||||
serialize.refs,
|
serialize.refs,
|
||||||
serialize.replacer,
|
serialize.replacer,
|
||||||
|
|
|
@ -1,26 +1,24 @@
|
||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
import { connect, ResolveThunks } from 'react-redux';
|
import { connect, ResolveThunks } from 'react-redux';
|
||||||
import { Button, Container, Divider, Toolbar } from '@redux-devtools/ui';
|
import { Button, Container, Divider, Toolbar } from '@redux-devtools/ui';
|
||||||
import SliderMonitor from '@redux-devtools/app/lib/containers/monitors/Slider';
|
|
||||||
import { liftedDispatch, getReport } from '@redux-devtools/app/lib/actions';
|
|
||||||
import { getActiveInstance } from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import DevTools from '@redux-devtools/app/lib/containers/DevTools';
|
|
||||||
import Dispatcher from '@redux-devtools/app/lib/containers/monitors/Dispatcher';
|
|
||||||
import TopButtons from '@redux-devtools/app/lib/components/TopButtons';
|
|
||||||
import ExportButton from '@redux-devtools/app/lib/components/buttons/ExportButton';
|
|
||||||
import ImportButton from '@redux-devtools/app/lib/components/buttons/ImportButton';
|
|
||||||
import PrintButton from '@redux-devtools/app/lib/components/buttons/PrintButton';
|
|
||||||
import MonitorSelector from '@redux-devtools/app/lib/components/MonitorSelector';
|
|
||||||
import SliderButton from '@redux-devtools/app/lib/components/buttons/SliderButton';
|
|
||||||
import DispatcherButton from '@redux-devtools/app/lib/components/buttons/DispatcherButton';
|
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
import { GoRadioTower } from 'react-icons/go';
|
|
||||||
import {
|
import {
|
||||||
MdBorderBottom,
|
DevTools,
|
||||||
MdBorderLeft,
|
Dispatcher,
|
||||||
MdBorderRight,
|
DispatcherButton,
|
||||||
MdSave,
|
ExportButton,
|
||||||
} from 'react-icons/md';
|
getActiveInstance,
|
||||||
|
getReport,
|
||||||
|
ImportButton,
|
||||||
|
liftedDispatch,
|
||||||
|
MonitorSelector,
|
||||||
|
PrintButton,
|
||||||
|
SliderButton,
|
||||||
|
SliderMonitor,
|
||||||
|
StoreState,
|
||||||
|
TopButtons,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
|
import { GoRadioTower } from 'react-icons/go';
|
||||||
|
import { MdBorderBottom, MdBorderLeft, MdBorderRight } from 'react-icons/md';
|
||||||
import { Position } from '../api/openWindow';
|
import { Position } from '../api/openWindow';
|
||||||
import { SingleMessage } from '../middlewares/api';
|
import { SingleMessage } from '../middlewares/api';
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,13 @@
|
||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
import { connect, ResolveThunks } from 'react-redux';
|
import { connect, ResolveThunks } from 'react-redux';
|
||||||
import { Container, Notification } from '@redux-devtools/ui';
|
import { Container, Notification } from '@redux-devtools/ui';
|
||||||
import { getActiveInstance } from '@redux-devtools/app/lib/reducers/instances';
|
import {
|
||||||
import Settings from '@redux-devtools/app/lib/components/Settings';
|
clearNotification,
|
||||||
import Header from '@redux-devtools/app/lib/components/Header';
|
getActiveInstance,
|
||||||
import { clearNotification } from '@redux-devtools/app/lib/actions';
|
Header,
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
Settings,
|
||||||
|
StoreState,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
import Actions from './Actions';
|
import Actions from './Actions';
|
||||||
|
|
||||||
type StateProps = ReturnType<typeof mapStateToProps>;
|
type StateProps = ReturnType<typeof mapStateToProps>;
|
||||||
|
|
|
@ -1,12 +1,16 @@
|
||||||
import stringifyJSON from '@redux-devtools/app/lib/utils/stringifyJSON';
|
|
||||||
import {
|
import {
|
||||||
UPDATE_STATE,
|
CustomAction,
|
||||||
REMOVE_INSTANCE,
|
DispatchAction as AppDispatchAction,
|
||||||
|
LibConfig,
|
||||||
LIFTED_ACTION,
|
LIFTED_ACTION,
|
||||||
TOGGLE_PERSIST,
|
nonReduxDispatch,
|
||||||
|
REMOVE_INSTANCE,
|
||||||
SET_PERSIST,
|
SET_PERSIST,
|
||||||
} from '@redux-devtools/app/lib/constants/actionTypes';
|
SetPersistAction,
|
||||||
import { nonReduxDispatch } from '@redux-devtools/app/lib/utils/monitorActions';
|
stringifyJSON,
|
||||||
|
TOGGLE_PERSIST,
|
||||||
|
UPDATE_STATE,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
import syncOptions, {
|
import syncOptions, {
|
||||||
Options,
|
Options,
|
||||||
OptionsMessage,
|
OptionsMessage,
|
||||||
|
@ -16,12 +20,6 @@ import openDevToolsWindow, {
|
||||||
DevToolsPosition,
|
DevToolsPosition,
|
||||||
} from '../../browser/extension/background/openWindow';
|
} from '../../browser/extension/background/openWindow';
|
||||||
import { getReport } from '../../browser/extension/background/logging';
|
import { getReport } from '../../browser/extension/background/logging';
|
||||||
import {
|
|
||||||
CustomAction,
|
|
||||||
DispatchAction as AppDispatchAction,
|
|
||||||
LibConfig,
|
|
||||||
SetPersistAction,
|
|
||||||
} from '@redux-devtools/app/lib/actions';
|
|
||||||
import { Action, Dispatch, MiddlewareAPI } from 'redux';
|
import { Action, Dispatch, MiddlewareAPI } from 'redux';
|
||||||
import {
|
import {
|
||||||
ContentScriptToBackgroundMessage,
|
ContentScriptToBackgroundMessage,
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
import { Dispatch, MiddlewareAPI } from 'redux';
|
import { Dispatch, MiddlewareAPI } from 'redux';
|
||||||
import {
|
import {
|
||||||
SELECT_INSTANCE,
|
SELECT_INSTANCE,
|
||||||
|
StoreAction,
|
||||||
|
StoreState,
|
||||||
UPDATE_STATE,
|
UPDATE_STATE,
|
||||||
} from '@redux-devtools/app/lib/constants/actionTypes';
|
} from '@redux-devtools/app';
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
|
|
||||||
function selectInstance(
|
function selectInstance(
|
||||||
tabId: number,
|
tabId: number,
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
import {
|
import {
|
||||||
|
getActiveInstance,
|
||||||
LIFTED_ACTION,
|
LIFTED_ACTION,
|
||||||
UPDATE_STATE,
|
|
||||||
SELECT_INSTANCE,
|
SELECT_INSTANCE,
|
||||||
|
StoreAction,
|
||||||
|
StoreState,
|
||||||
TOGGLE_PERSIST,
|
TOGGLE_PERSIST,
|
||||||
} from '@redux-devtools/app/lib/constants/actionTypes';
|
UPDATE_STATE,
|
||||||
import { getActiveInstance } from '@redux-devtools/app/lib/reducers/instances';
|
} from '@redux-devtools/app';
|
||||||
import { Dispatch, MiddlewareAPI } from 'redux';
|
import { Dispatch, MiddlewareAPI } from 'redux';
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
|
||||||
|
|
||||||
function panelDispatcher(bgConnection: chrome.runtime.Port) {
|
function panelDispatcher(bgConnection: chrome.runtime.Port) {
|
||||||
let autoselected = false;
|
let autoselected = false;
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
import {
|
import {
|
||||||
UPDATE_STATE,
|
getActiveInstance,
|
||||||
LIFTED_ACTION,
|
LIFTED_ACTION,
|
||||||
|
StoreAction,
|
||||||
|
StoreState,
|
||||||
TOGGLE_PERSIST,
|
TOGGLE_PERSIST,
|
||||||
} from '@redux-devtools/app/lib/constants/actionTypes';
|
UPDATE_STATE,
|
||||||
import { getActiveInstance } from '@redux-devtools/app/lib/reducers/instances';
|
} from '@redux-devtools/app';
|
||||||
import { Dispatch, MiddlewareAPI, Store } from 'redux';
|
import { Dispatch, MiddlewareAPI, Store } from 'redux';
|
||||||
import { BackgroundState } from '../reducers/background';
|
import { BackgroundState } from '../reducers/background';
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
|
||||||
import { WindowStoreAction } from '../stores/windowStore';
|
import { WindowStoreAction } from '../stores/windowStore';
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
import { BackgroundAction } from '../stores/backgroundStore';
|
import { BackgroundAction } from '../stores/backgroundStore';
|
||||||
|
|
||||||
const syncStores =
|
const syncStores =
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
import { combineReducers, Reducer } from 'redux';
|
import { combineReducers, Reducer } from 'redux';
|
||||||
import instances, {
|
import { instances, InstancesState } from '@redux-devtools/app';
|
||||||
InstancesState,
|
|
||||||
} from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import { BackgroundAction } from '../../stores/backgroundStore';
|
import { BackgroundAction } from '../../stores/backgroundStore';
|
||||||
|
|
||||||
export interface BackgroundState {
|
export interface BackgroundState {
|
||||||
|
|
|
@ -1,24 +1,21 @@
|
||||||
import { combineReducers, Reducer } from 'redux';
|
import { combineReducers, Reducer } from 'redux';
|
||||||
import instances, {
|
import {
|
||||||
InstancesState,
|
connection,
|
||||||
} from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import monitor, {
|
|
||||||
MonitorState,
|
|
||||||
} from '@redux-devtools/app/lib/reducers/monitor';
|
|
||||||
import notification, {
|
|
||||||
NotificationState,
|
|
||||||
} from '@redux-devtools/app/lib/reducers/notification';
|
|
||||||
import reports, {
|
|
||||||
ReportsState,
|
|
||||||
} from '@redux-devtools/app/lib/reducers/reports';
|
|
||||||
import section, {
|
|
||||||
SectionState,
|
|
||||||
} from '@redux-devtools/app/lib/reducers/section';
|
|
||||||
import theme, { ThemeState } from '@redux-devtools/app/lib/reducers/theme';
|
|
||||||
import connection, {
|
|
||||||
ConnectionState,
|
ConnectionState,
|
||||||
} from '@redux-devtools/app/lib/reducers/connection';
|
instances,
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
InstancesState,
|
||||||
|
monitor,
|
||||||
|
MonitorState,
|
||||||
|
notification,
|
||||||
|
NotificationState,
|
||||||
|
reports,
|
||||||
|
ReportsState,
|
||||||
|
section,
|
||||||
|
SectionState,
|
||||||
|
StoreAction,
|
||||||
|
theme,
|
||||||
|
ThemeState,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
|
|
||||||
export interface StoreStateWithoutSocket {
|
export interface StoreStateWithoutSocket {
|
||||||
readonly section: SectionState;
|
readonly section: SectionState;
|
||||||
|
|
|
@ -1,13 +1,15 @@
|
||||||
import { combineReducers, Reducer } from 'redux';
|
import { combineReducers, Reducer } from 'redux';
|
||||||
|
import {
|
||||||
|
connection,
|
||||||
|
monitor,
|
||||||
|
notification,
|
||||||
|
reports,
|
||||||
|
section,
|
||||||
|
socket,
|
||||||
|
theme,
|
||||||
|
StoreState,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
import instances from './instances';
|
import instances from './instances';
|
||||||
import monitor from '@redux-devtools/app/lib/reducers/monitor';
|
|
||||||
import notification from '@redux-devtools/app/lib/reducers/notification';
|
|
||||||
import socket from '@redux-devtools/app/lib/reducers/socket';
|
|
||||||
import reports from '@redux-devtools/app/lib/reducers/reports';
|
|
||||||
import section from '@redux-devtools/app/lib/reducers/section';
|
|
||||||
import theme from '@redux-devtools/app/lib/reducers/theme';
|
|
||||||
import connection from '@redux-devtools/app/lib/reducers/connection';
|
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
import { WindowStoreAction } from '../../stores/windowStore';
|
import { WindowStoreAction } from '../../stores/windowStore';
|
||||||
|
|
||||||
const rootReducer: Reducer<StoreState, WindowStoreAction> =
|
const rootReducer: Reducer<StoreState, WindowStoreAction> =
|
||||||
|
|
|
@ -1,20 +1,18 @@
|
||||||
import {
|
import {
|
||||||
initialState,
|
instancesInitialState,
|
||||||
dispatchAction,
|
dispatchAction,
|
||||||
} from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import {
|
|
||||||
UPDATE_STATE,
|
UPDATE_STATE,
|
||||||
SELECT_INSTANCE,
|
SELECT_INSTANCE,
|
||||||
LIFTED_ACTION,
|
LIFTED_ACTION,
|
||||||
SET_PERSIST,
|
SET_PERSIST,
|
||||||
} from '@redux-devtools/app/lib/constants/actionTypes';
|
} from '@redux-devtools/app';
|
||||||
import {
|
import {
|
||||||
ExpandedUpdateStateAction,
|
ExpandedUpdateStateAction,
|
||||||
WindowStoreAction,
|
WindowStoreAction,
|
||||||
} from '../../stores/windowStore';
|
} from '../../stores/windowStore';
|
||||||
|
|
||||||
export default function instances(
|
export default function instances(
|
||||||
state = initialState,
|
state = instancesInitialState,
|
||||||
action: WindowStoreAction
|
action: WindowStoreAction
|
||||||
) {
|
) {
|
||||||
switch (action.type) {
|
switch (action.type) {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import { Action } from 'redux';
|
import { Action } from 'redux';
|
||||||
import { LiftedState } from '@redux-devtools/instrument';
|
import { LiftedState } from '@redux-devtools/instrument';
|
||||||
import { DispatchAction, LibConfig } from '@redux-devtools/app/lib/actions';
|
import { DispatchAction, LibConfig } from '@redux-devtools/app';
|
||||||
|
|
||||||
declare global {
|
declare global {
|
||||||
interface Window {
|
interface Window {
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
import { createStore, applyMiddleware, PreloadedState } from 'redux';
|
import { createStore, applyMiddleware, PreloadedState } from 'redux';
|
||||||
import rootReducer, { BackgroundState } from '../reducers/background';
|
|
||||||
import api, { CONNECTED, DISCONNECTED } from '../middlewares/api';
|
|
||||||
import { LIFTED_ACTION } from '@redux-devtools/app/lib/constants/actionTypes';
|
|
||||||
import {
|
import {
|
||||||
CustomAction,
|
CustomAction,
|
||||||
DispatchAction,
|
DispatchAction,
|
||||||
|
LIFTED_ACTION,
|
||||||
StoreActionWithoutLiftedAction,
|
StoreActionWithoutLiftedAction,
|
||||||
} from '@redux-devtools/app/lib/actions';
|
} from '@redux-devtools/app';
|
||||||
|
import rootReducer, { BackgroundState } from '../reducers/background';
|
||||||
|
import api, { CONNECTED, DISCONNECTED } from '../middlewares/api';
|
||||||
|
|
||||||
interface LiftedActionActionBase {
|
interface LiftedActionActionBase {
|
||||||
action?: DispatchAction | string | CustomAction;
|
action?: DispatchAction | string | CustomAction;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import { Action, compose, Reducer, StoreEnhancerStoreCreator } from 'redux';
|
import { Action, compose, Reducer, StoreEnhancerStoreCreator } from 'redux';
|
||||||
import instrument from '@redux-devtools/instrument';
|
import { instrument } from '@redux-devtools/instrument';
|
||||||
import persistState from '@redux-devtools/core/lib/persistState';
|
import { persistState } from '@redux-devtools/core';
|
||||||
import { ConfigWithExpandedMaxAge } from '../../browser/extension/inject/pageScript';
|
import { ConfigWithExpandedMaxAge } from '../../browser/extension/inject/pageScript';
|
||||||
|
|
||||||
export function getUrlParam(key: string) {
|
export function getUrlParam(key: string) {
|
||||||
|
|
|
@ -1,10 +1,9 @@
|
||||||
import { createStore, applyMiddleware, PreloadedState, Reducer } from 'redux';
|
import { createStore, applyMiddleware, Reducer } from 'redux';
|
||||||
import localForage from 'localforage';
|
import localForage from 'localforage';
|
||||||
import { persistReducer, persistStore } from 'redux-persist';
|
import { persistReducer, persistStore } from 'redux-persist';
|
||||||
import exportState from '@redux-devtools/app/lib/middlewares/exportState';
|
import { exportStateMiddleware, StoreAction } from '@redux-devtools/app';
|
||||||
import panelDispatcher from '../middlewares/panelSync';
|
import panelDispatcher from '../middlewares/panelSync';
|
||||||
import rootReducer, { StoreStateWithoutSocket } from '../reducers/panel';
|
import rootReducer, { StoreStateWithoutSocket } from '../reducers/panel';
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
|
||||||
|
|
||||||
const persistConfig = {
|
const persistConfig = {
|
||||||
key: 'redux-devtools',
|
key: 'redux-devtools',
|
||||||
|
@ -19,7 +18,10 @@ export default function configureStore(
|
||||||
position: string,
|
position: string,
|
||||||
bgConnection: chrome.runtime.Port
|
bgConnection: chrome.runtime.Port
|
||||||
) {
|
) {
|
||||||
const enhancer = applyMiddleware(exportState, panelDispatcher(bgConnection));
|
const enhancer = applyMiddleware(
|
||||||
|
exportStateMiddleware,
|
||||||
|
panelDispatcher(bgConnection)
|
||||||
|
);
|
||||||
const store = createStore(persistedReducer, enhancer);
|
const store = createStore(persistedReducer, enhancer);
|
||||||
const persistor = persistStore(store);
|
const persistor = persistStore(store);
|
||||||
return { store, persistor };
|
return { store, persistor };
|
||||||
|
|
|
@ -8,21 +8,21 @@ import {
|
||||||
} from 'redux';
|
} from 'redux';
|
||||||
import localForage from 'localforage';
|
import localForage from 'localforage';
|
||||||
import { persistReducer, persistStore } from 'redux-persist';
|
import { persistReducer, persistStore } from 'redux-persist';
|
||||||
import exportState from '@redux-devtools/app/lib/middlewares/exportState';
|
|
||||||
import api from '@redux-devtools/app/lib/middlewares/api';
|
|
||||||
import { CONNECT_REQUEST } from '@redux-devtools/app/lib/constants/socketActionTypes';
|
|
||||||
import {
|
import {
|
||||||
|
api,
|
||||||
|
CONNECT_REQUEST,
|
||||||
|
exportStateMiddleware,
|
||||||
|
InstancesState,
|
||||||
StoreActionWithoutUpdateState,
|
StoreActionWithoutUpdateState,
|
||||||
|
StoreState,
|
||||||
UpdateStateAction,
|
UpdateStateAction,
|
||||||
} from '@redux-devtools/app/lib/actions';
|
} from '@redux-devtools/app';
|
||||||
import { InstancesState } from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import syncStores from '../middlewares/windowSync';
|
import syncStores from '../middlewares/windowSync';
|
||||||
import instanceSelector from '../middlewares/instanceSelector';
|
import instanceSelector from '../middlewares/instanceSelector';
|
||||||
import rootReducer from '../reducers/window';
|
import rootReducer from '../reducers/window';
|
||||||
import { BackgroundState } from '../reducers/background';
|
import { BackgroundState } from '../reducers/background';
|
||||||
import { BackgroundAction } from './backgroundStore';
|
import { BackgroundAction } from './backgroundStore';
|
||||||
import { EmptyUpdateStateAction, NAAction } from '../middlewares/api';
|
import { EmptyUpdateStateAction, NAAction } from '../middlewares/api';
|
||||||
import { StoreState } from '@redux-devtools/app/lib/reducers';
|
|
||||||
|
|
||||||
export interface ExpandedUpdateStateAction extends UpdateStateAction {
|
export interface ExpandedUpdateStateAction extends UpdateStateAction {
|
||||||
readonly instances: InstancesState;
|
readonly instances: InstancesState;
|
||||||
|
@ -50,7 +50,7 @@ export default function configureStore(
|
||||||
position: string
|
position: string
|
||||||
) {
|
) {
|
||||||
let enhancer: StoreEnhancer;
|
let enhancer: StoreEnhancer;
|
||||||
const middlewares = [exportState, api, syncStores(baseStore)];
|
const middlewares = [exportStateMiddleware, api, syncStores(baseStore)];
|
||||||
if (!position || position === '#popup') {
|
if (!position || position === '#popup') {
|
||||||
// select current tab instance for devPanel and pageAction
|
// select current tab instance for devPanel and pageAction
|
||||||
middlewares.push(instanceSelector);
|
middlewares.push(instanceSelector);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { LIFTED_ACTION } from '@redux-devtools/app/lib/constants/actionTypes';
|
import { LIFTED_ACTION } from '@redux-devtools/app';
|
||||||
|
|
||||||
export function getReport(
|
export function getReport(
|
||||||
reportId: string,
|
reportId: string,
|
||||||
|
|
|
@ -2,13 +2,12 @@ import React, { CSSProperties } from 'react';
|
||||||
import { render, unmountComponentAtNode } from 'react-dom';
|
import { render, unmountComponentAtNode } from 'react-dom';
|
||||||
import { Provider } from 'react-redux';
|
import { Provider } from 'react-redux';
|
||||||
import { Persistor } from 'redux-persist';
|
import { Persistor } from 'redux-persist';
|
||||||
import { REMOVE_INSTANCE } from '@redux-devtools/app/lib/constants/actionTypes';
|
import { REMOVE_INSTANCE, StoreAction } from '@redux-devtools/app';
|
||||||
import App from '../../../app/containers/App';
|
import App from '../../../app/containers/App';
|
||||||
import configureStore from '../../../app/stores/panelStore';
|
import configureStore from '../../../app/stores/panelStore';
|
||||||
|
|
||||||
import '../../views/devpanel.pug';
|
import '../../views/devpanel.pug';
|
||||||
import { Action, Store } from 'redux';
|
import { Action, Store } from 'redux';
|
||||||
import { StoreAction } from '@redux-devtools/app/lib/actions';
|
|
||||||
import { PanelMessage } from '../../../app/middlewares/api';
|
import { PanelMessage } from '../../../app/middlewares/api';
|
||||||
import { StoreStateWithoutSocket } from '../../../app/reducers/panel';
|
import { StoreStateWithoutSocket } from '../../../app/reducers/panel';
|
||||||
import { PersistGate } from 'redux-persist/integration/react';
|
import { PersistGate } from 'redux-persist/integration/react';
|
||||||
|
|
|
@ -13,7 +13,7 @@ import { Action } from 'redux';
|
||||||
import {
|
import {
|
||||||
CustomAction,
|
CustomAction,
|
||||||
DispatchAction as AppDispatchAction,
|
DispatchAction as AppDispatchAction,
|
||||||
} from '@redux-devtools/app/lib/actions';
|
} from '@redux-devtools/app';
|
||||||
import { LiftedState } from '@redux-devtools/instrument';
|
import { LiftedState } from '@redux-devtools/instrument';
|
||||||
const source = '@devtools-extension';
|
const source = '@devtools-extension';
|
||||||
const pageSource = '@devtools-page';
|
const pageSource = '@devtools-page';
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
import {
|
import {
|
||||||
getActionsArray,
|
|
||||||
evalAction,
|
|
||||||
ActionCreatorObject,
|
ActionCreatorObject,
|
||||||
|
evalAction,
|
||||||
|
getActionsArray,
|
||||||
|
getLocalFilter,
|
||||||
} from '@redux-devtools/utils';
|
} from '@redux-devtools/utils';
|
||||||
import throttle from 'lodash/throttle';
|
import throttle from 'lodash/throttle';
|
||||||
import {
|
import {
|
||||||
|
@ -14,7 +15,18 @@ import {
|
||||||
StoreEnhancerStoreCreator,
|
StoreEnhancerStoreCreator,
|
||||||
} from 'redux';
|
} from 'redux';
|
||||||
import Immutable from 'immutable';
|
import Immutable from 'immutable';
|
||||||
import { EnhancedStore, PerformAction } from '@redux-devtools/instrument';
|
import {
|
||||||
|
EnhancedStore,
|
||||||
|
LiftedAction,
|
||||||
|
LiftedState,
|
||||||
|
PerformAction,
|
||||||
|
} from '@redux-devtools/instrument';
|
||||||
|
import {
|
||||||
|
CustomAction,
|
||||||
|
DispatchAction,
|
||||||
|
LibConfig,
|
||||||
|
Features,
|
||||||
|
} from '@redux-devtools/app';
|
||||||
import configureStore, { getUrlParam } from '../../../app/stores/enhancerStore';
|
import configureStore, { getUrlParam } from '../../../app/stores/enhancerStore';
|
||||||
import { isAllowed, Options } from '../options/syncOptions';
|
import { isAllowed, Options } from '../options/syncOptions';
|
||||||
import Monitor from '../../../app/service/Monitor';
|
import Monitor from '../../../app/service/Monitor';
|
||||||
|
@ -40,15 +52,7 @@ import {
|
||||||
StructuralPerformAction,
|
StructuralPerformAction,
|
||||||
ConnectResponse,
|
ConnectResponse,
|
||||||
} from '../../../app/api';
|
} from '../../../app/api';
|
||||||
import { LiftedAction, LiftedState } from '@redux-devtools/instrument';
|
|
||||||
import {
|
|
||||||
CustomAction,
|
|
||||||
DispatchAction,
|
|
||||||
LibConfig,
|
|
||||||
} from '@redux-devtools/app/lib/actions';
|
|
||||||
import { ContentScriptToPageScriptMessage } from './contentScript';
|
import { ContentScriptToPageScriptMessage } from './contentScript';
|
||||||
import { Features } from '@redux-devtools/app/lib/reducers/instances';
|
|
||||||
import { getLocalFilter } from '@redux-devtools/utils/lib/filters';
|
|
||||||
|
|
||||||
type EnhancedStoreWithInitialDispatch<
|
type EnhancedStoreWithInitialDispatch<
|
||||||
S,
|
S,
|
||||||
|
|
|
@ -2,7 +2,7 @@ import React from 'react';
|
||||||
import { render } from 'react-dom';
|
import { render } from 'react-dom';
|
||||||
import { Provider } from 'react-redux';
|
import { Provider } from 'react-redux';
|
||||||
import { PersistGate } from 'redux-persist/integration/react';
|
import { PersistGate } from 'redux-persist/integration/react';
|
||||||
import { UPDATE_STATE } from '@redux-devtools/app/lib/constants/actionTypes';
|
import { UPDATE_STATE } from '@redux-devtools/app';
|
||||||
import App from '../../../app/containers/App';
|
import App from '../../../app/containers/App';
|
||||||
import configureStore from '../../../app/stores/windowStore';
|
import configureStore from '../../../app/stores/windowStore';
|
||||||
import { MonitorMessage } from '../../../app/middlewares/api';
|
import { MonitorMessage } from '../../../app/middlewares/api';
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { render } from 'react-dom';
|
import { render } from 'react-dom';
|
||||||
import App from '@redux-devtools/app';
|
import { Root } from '@redux-devtools/app';
|
||||||
|
|
||||||
import '../../views/remote.pug';
|
import '../../views/remote.pug';
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ chrome.storage.local.get(
|
||||||
's:secure': null,
|
's:secure': null,
|
||||||
},
|
},
|
||||||
(options) => {
|
(options) => {
|
||||||
const AppAsAny = App as any;
|
const AppAsAny = Root as any;
|
||||||
render(
|
render(
|
||||||
<AppAsAny
|
<AppAsAny
|
||||||
selectMonitor={options['select-monitor']}
|
selectMonitor={options['select-monitor']}
|
||||||
|
|
|
@ -8,7 +8,7 @@ interface State {
|
||||||
}
|
}
|
||||||
|
|
||||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
// eslint-disable-next-line @typescript-eslint/ban-types
|
||||||
class Settings extends Component<{}, State> {
|
export default class Settings extends Component<{}, State> {
|
||||||
tabs = [
|
tabs = [
|
||||||
{ name: 'Connection', component: Connection },
|
{ name: 'Connection', component: Connection },
|
||||||
{ name: 'Themes', component: Themes },
|
{ name: 'Themes', component: Themes },
|
||||||
|
@ -30,5 +30,3 @@ class Settings extends Component<{}, State> {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default Settings;
|
|
||||||
|
|
|
@ -38,3 +38,32 @@ export class Root extends Component {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export * from './actions';
|
||||||
|
export { default as DispatcherButton } from './components/buttons/DispatcherButton';
|
||||||
|
export { default as ExportButton } from './components/buttons/ExportButton';
|
||||||
|
export { default as ImportButton } from './components/buttons/ImportButton';
|
||||||
|
export { default as PrintButton } from './components/buttons/PrintButton';
|
||||||
|
export { default as SliderButton } from './components/buttons/SliderButton';
|
||||||
|
export { default as Header } from './components/Header';
|
||||||
|
export { default as MonitorSelector } from './components/MonitorSelector';
|
||||||
|
export { default as Settings } from './components/Settings';
|
||||||
|
export { default as TopButtons } from './components/TopButtons';
|
||||||
|
export { default as DevTools } from './containers/DevTools';
|
||||||
|
export { default as Dispatcher } from './containers/monitors/Dispatcher';
|
||||||
|
export { default as SliderMonitor } from './containers/monitors/Slider';
|
||||||
|
export * from './constants/actionTypes';
|
||||||
|
export * from './constants/socketActionTypes';
|
||||||
|
export * from './middlewares/api';
|
||||||
|
export * from './middlewares/exportState';
|
||||||
|
export * from './reducers';
|
||||||
|
export * from './reducers/connection';
|
||||||
|
export * from './reducers/instances';
|
||||||
|
export * from './reducers/monitor';
|
||||||
|
export * from './reducers/notification';
|
||||||
|
export * from './reducers/reports';
|
||||||
|
export * from './reducers/section';
|
||||||
|
export * from './reducers/socket';
|
||||||
|
export * from './reducers/theme';
|
||||||
|
export * from './utils/monitorActions';
|
||||||
|
export * from './utils/stringifyJSON';
|
||||||
|
|
|
@ -244,9 +244,7 @@ function getReport(reportId: unknown) {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function api(
|
export function api(inStore: MiddlewareAPI<Dispatch<StoreAction>, StoreState>) {
|
||||||
inStore: MiddlewareAPI<Dispatch<StoreAction>, StoreState>
|
|
||||||
) {
|
|
||||||
store = inStore;
|
store = inStore;
|
||||||
return (next: Dispatch<StoreAction>) => (action: StoreAction) => {
|
return (next: Dispatch<StoreAction>) => (action: StoreAction) => {
|
||||||
const result = next(action);
|
const result = next(action);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import stringifyJSON from '../utils/stringifyJSON';
|
import { stringifyJSON } from '../utils/stringifyJSON';
|
||||||
import { UPDATE_STATE, LIFTED_ACTION, EXPORT } from '../constants/actionTypes';
|
import { UPDATE_STATE, LIFTED_ACTION, EXPORT } from '../constants/actionTypes';
|
||||||
import { getActiveInstance } from '../reducers/instances';
|
import { getActiveInstance } from '../reducers/instances';
|
||||||
import { Dispatch, MiddlewareAPI } from 'redux';
|
import { Dispatch, MiddlewareAPI } from 'redux';
|
||||||
|
@ -22,7 +22,7 @@ function download(state: string) {
|
||||||
}, 0);
|
}, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
const exportState =
|
export const exportStateMiddleware =
|
||||||
(store: MiddlewareAPI<Dispatch<StoreAction>, StoreState>) =>
|
(store: MiddlewareAPI<Dispatch<StoreAction>, StoreState>) =>
|
||||||
(next: Dispatch<StoreAction>) =>
|
(next: Dispatch<StoreAction>) =>
|
||||||
(action: StoreAction) => {
|
(action: StoreAction) => {
|
||||||
|
@ -63,5 +63,3 @@ const exportState =
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default exportState;
|
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
import { RECONNECT } from '../constants/socketActionTypes';
|
import { RECONNECT } from '../constants/socketActionTypes';
|
||||||
import { ConnectionType, StoreAction } from '../actions';
|
import { ConnectionType, StoreAction } from '../actions';
|
||||||
|
|
||||||
export interface ConnectionOptions {
|
export interface ConnectionStateOptions {
|
||||||
readonly hostname: string;
|
readonly hostname: string;
|
||||||
readonly port: number;
|
readonly port: number;
|
||||||
readonly secure: boolean;
|
readonly secure: boolean;
|
||||||
}
|
}
|
||||||
export interface ConnectionState {
|
export interface ConnectionState {
|
||||||
readonly options: ConnectionOptions;
|
readonly options: ConnectionStateOptions;
|
||||||
readonly type: ConnectionType;
|
readonly type: ConnectionType;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function connection(
|
export function connection(
|
||||||
state: ConnectionState = {
|
state: ConnectionState = {
|
||||||
options: { hostname: 'localhost', port: 8000, secure: false },
|
options: { hostname: 'localhost', port: 8000, secure: false },
|
||||||
type: 'disabled',
|
type: 'disabled',
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
import { combineReducers } from 'redux';
|
import { combineReducers } from 'redux';
|
||||||
import section, { SectionState } from './section';
|
import { section, SectionState } from './section';
|
||||||
import connection, { ConnectionState } from './connection';
|
import { connection, ConnectionState } from './connection';
|
||||||
import socket, { SocketState } from './socket';
|
import { socket, SocketState } from './socket';
|
||||||
import monitor, { MonitorState } from './monitor';
|
import { monitor, MonitorState } from './monitor';
|
||||||
import notification, { NotificationState } from './notification';
|
import { notification, NotificationState } from './notification';
|
||||||
import instances, { InstancesState } from './instances';
|
import { instances, InstancesState } from './instances';
|
||||||
import reports, { ReportsState } from './reports';
|
import { reports, ReportsState } from './reports';
|
||||||
import theme, { ThemeState } from './theme';
|
import { theme, ThemeState } from './theme';
|
||||||
import { StoreAction } from '../actions';
|
import { StoreAction } from '../actions';
|
||||||
|
|
||||||
export interface StoreState {
|
export interface StoreState {
|
||||||
|
@ -20,7 +20,7 @@ export interface StoreState {
|
||||||
readonly notification: NotificationState;
|
readonly notification: NotificationState;
|
||||||
}
|
}
|
||||||
|
|
||||||
const rootReducer = combineReducers<StoreState, StoreAction>({
|
export const rootReducer = combineReducers<StoreState, StoreAction>({
|
||||||
section,
|
section,
|
||||||
theme,
|
theme,
|
||||||
connection,
|
connection,
|
||||||
|
@ -30,5 +30,3 @@ const rootReducer = combineReducers<StoreState, StoreAction>({
|
||||||
reports,
|
reports,
|
||||||
notification,
|
notification,
|
||||||
});
|
});
|
||||||
|
|
||||||
export default rootReducer;
|
|
||||||
|
|
|
@ -66,7 +66,7 @@ export interface InstancesState {
|
||||||
persisted?: boolean;
|
persisted?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export const initialState: InstancesState = {
|
export const instancesInitialState: InstancesState = {
|
||||||
selected: null,
|
selected: null,
|
||||||
current: 'default',
|
current: 'default',
|
||||||
sync: false,
|
sync: false,
|
||||||
|
@ -303,8 +303,8 @@ function init(
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function instances(
|
export function instances(
|
||||||
state = initialState,
|
state = instancesInitialState,
|
||||||
action: StoreAction
|
action: StoreAction
|
||||||
): InstancesState {
|
): InstancesState {
|
||||||
switch (action.type) {
|
switch (action.type) {
|
||||||
|
@ -375,7 +375,7 @@ export default function instances(
|
||||||
return state;
|
return state;
|
||||||
}
|
}
|
||||||
case DISCONNECTED:
|
case DISCONNECTED:
|
||||||
return initialState;
|
return instancesInitialState;
|
||||||
default:
|
default:
|
||||||
return state;
|
return state;
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,7 +45,7 @@ export function dispatchMonitorAction(
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function monitor(
|
export function monitor(
|
||||||
state = initialState,
|
state = initialState,
|
||||||
action: StoreAction
|
action: StoreAction
|
||||||
): MonitorState {
|
): MonitorState {
|
||||||
|
|
|
@ -12,7 +12,7 @@ interface Notification {
|
||||||
}
|
}
|
||||||
export type NotificationState = Notification | null;
|
export type NotificationState = Notification | null;
|
||||||
|
|
||||||
export default function notification(
|
export function notification(
|
||||||
state: NotificationState = null,
|
state: NotificationState = null,
|
||||||
action: StoreAction
|
action: StoreAction
|
||||||
): NotificationState {
|
): NotificationState {
|
||||||
|
|
|
@ -15,7 +15,7 @@ const initialState: ReportsState = {
|
||||||
data: [],
|
data: [],
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function reports(
|
export function reports(
|
||||||
state = initialState,
|
state = initialState,
|
||||||
action: StoreAction
|
action: StoreAction
|
||||||
): ReportsState {
|
): ReportsState {
|
||||||
|
|
|
@ -3,7 +3,7 @@ import { StoreAction } from '../actions';
|
||||||
|
|
||||||
export type SectionState = string;
|
export type SectionState = string;
|
||||||
|
|
||||||
export default function section(state = 'Actions', action: StoreAction) {
|
export function section(state = 'Actions', action: StoreAction) {
|
||||||
if (action.type === CHANGE_SECTION) {
|
if (action.type === CHANGE_SECTION) {
|
||||||
return action.section;
|
return action.section;
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,10 +20,7 @@ const initialState: SocketState = {
|
||||||
error: undefined,
|
error: undefined,
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function socket(
|
export function socket(state = initialState, action: StoreAction): SocketState {
|
||||||
state = initialState,
|
|
||||||
action: StoreAction
|
|
||||||
): SocketState {
|
|
||||||
switch (action.type) {
|
switch (action.type) {
|
||||||
case actions.CONNECT_REQUEST: {
|
case actions.CONNECT_REQUEST: {
|
||||||
return {
|
return {
|
||||||
|
|
|
@ -8,7 +8,7 @@ export interface ThemeState {
|
||||||
readonly colorPreference: 'auto' | 'light' | 'dark';
|
readonly colorPreference: 'auto' | 'light' | 'dark';
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function theme(
|
export function theme(
|
||||||
state: ThemeState = {
|
state: ThemeState = {
|
||||||
theme: 'default',
|
theme: 'default',
|
||||||
scheme: 'default',
|
scheme: 'default',
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
import { createStore, compose, applyMiddleware, Reducer, Store } from 'redux';
|
import { createStore, compose, applyMiddleware, Reducer, Store } from 'redux';
|
||||||
import localForage from 'localforage';
|
import localForage from 'localforage';
|
||||||
import { persistReducer, persistStore } from 'redux-persist';
|
import { persistReducer, persistStore } from 'redux-persist';
|
||||||
import api from '../middlewares/api';
|
import { api } from '../middlewares/api';
|
||||||
import exportState from '../middlewares/exportState';
|
import { exportStateMiddleware } from '../middlewares/exportState';
|
||||||
import rootReducer, { StoreState } from '../reducers';
|
import { rootReducer, StoreState } from '../reducers';
|
||||||
import { StoreAction } from '../actions';
|
import { StoreAction } from '../actions';
|
||||||
|
|
||||||
const persistConfig = {
|
const persistConfig = {
|
||||||
|
@ -47,7 +47,7 @@ export default function configureStore(
|
||||||
|
|
||||||
const store = createStore(
|
const store = createStore(
|
||||||
persistedReducer,
|
persistedReducer,
|
||||||
composeEnhancers(applyMiddleware(exportState, api))
|
composeEnhancers(applyMiddleware(exportStateMiddleware, api))
|
||||||
);
|
);
|
||||||
const persistor = persistStore(store, null, () => {
|
const persistor = persistStore(store, null, () => {
|
||||||
callback(store);
|
callback(store);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import difference from 'lodash/difference';
|
import difference from 'lodash/difference';
|
||||||
import omit from 'lodash/omit';
|
import omit from 'lodash/omit';
|
||||||
import stringifyJSON from './stringifyJSON';
|
import { stringifyJSON } from './stringifyJSON';
|
||||||
import { SET_STATE } from '../constants/actionTypes';
|
import { SET_STATE } from '../constants/actionTypes';
|
||||||
import { InstancesState, State } from '../reducers/instances';
|
import { InstancesState, State } from '../reducers/instances';
|
||||||
import { Dispatch, MiddlewareAPI } from 'redux';
|
import { Dispatch, MiddlewareAPI } from 'redux';
|
||||||
|
|
|
@ -14,10 +14,7 @@ function replacer(key: string, value: unknown) {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function stringifyJSON(
|
export function stringifyJSON(data: unknown, serialize: boolean | undefined) {
|
||||||
data: unknown,
|
|
||||||
serialize: boolean | undefined
|
|
||||||
) {
|
|
||||||
return serialize
|
return serialize
|
||||||
? jsan.stringify(data, replacer, null as unknown as undefined, true)
|
? jsan.stringify(data, replacer, null as unknown as undefined, true)
|
||||||
: jsan.stringify(data);
|
: jsan.stringify(data);
|
||||||
|
|
|
@ -22,7 +22,7 @@ const config = [
|
||||||
plugins: ['@babel/plugin-transform-runtime'],
|
plugins: ['@babel/plugin-transform-runtime'],
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
external: [/@babel\/runtime/],
|
external: [/@babel\/runtime/, 'redux'],
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -6,11 +6,11 @@ const config = [
|
||||||
input: 'src/index.ts',
|
input: 'src/index.ts',
|
||||||
output: [
|
output: [
|
||||||
{
|
{
|
||||||
file: 'dist/redux-devtools-log-monitor.cjs.js',
|
file: 'dist/redux-devtools-serialize.cjs.js',
|
||||||
format: 'cjs',
|
format: 'cjs',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
file: 'dist/redux-devtools-log-monitor.esm.js',
|
file: 'dist/redux-devtools-serialize.esm.js',
|
||||||
format: 'esm',
|
format: 'esm',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
|
@ -6,11 +6,11 @@ const config = [
|
||||||
input: 'src/index.ts',
|
input: 'src/index.ts',
|
||||||
output: [
|
output: [
|
||||||
{
|
{
|
||||||
file: 'dist/redux-devtools-serialize.cjs.js',
|
file: 'dist/redux-devtools-utils.cjs.js',
|
||||||
format: 'cjs',
|
format: 'cjs',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
file: 'dist/redux-devtools-serialize.esm.js',
|
file: 'dist/redux-devtools-utils.esm.js',
|
||||||
format: 'esm',
|
format: 'esm',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in New Issue
Block a user