Use lodash-es instead of lodash in extension

Produces (slightly) smaller bundles
This commit is contained in:
Nathan Bierema 2024-08-13 22:37:59 -04:00
parent 73688e117a
commit 1b12c51cb1
5 changed files with 10 additions and 17 deletions

View File

@ -35,7 +35,7 @@
"@types/jsan": "^3.1.5", "@types/jsan": "^3.1.5",
"jsan": "^3.1.14", "jsan": "^3.1.14",
"localforage": "^1.10.0", "localforage": "^1.10.0",
"lodash": "^4.17.21", "lodash-es": "^4.17.21",
"react": "^18.3.1", "react": "^18.3.1",
"react-dom": "^18.3.1", "react-dom": "^18.3.1",
"react-icons": "^5.2.1", "react-icons": "^5.2.1",
@ -56,7 +56,7 @@
"@testing-library/jest-dom": "^6.4.8", "@testing-library/jest-dom": "^6.4.8",
"@testing-library/react": "^16.0.0", "@testing-library/react": "^16.0.0",
"@types/chrome": "^0.0.269", "@types/chrome": "^0.0.269",
"@types/lodash": "^4.17.7", "@types/lodash-es": "^4.17.12",
"@types/react": "^18.3.3", "@types/react": "^18.3.3",
"@types/react-dom": "^18.3.0", "@types/react-dom": "^18.3.0",
"@types/styled-components": "^5.1.34", "@types/styled-components": "^5.1.34",

View File

@ -1,4 +1,4 @@
import mapValues from 'lodash/mapValues'; import { mapValues } from 'lodash-es';
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'; import { LocalFilter } from '@redux-devtools/utils';

View File

@ -1,5 +1,5 @@
import jsan, { Options } from 'jsan'; import jsan, { Options } from 'jsan';
import throttle from 'lodash/throttle'; import { throttle } from 'lodash-es';
import { immutableSerialize } from '@redux-devtools/serialize'; import { immutableSerialize } from '@redux-devtools/serialize';
import { getActionsArray, getLocalFilter } from '@redux-devtools/utils'; import { getActionsArray, getLocalFilter } from '@redux-devtools/utils';
import { isFiltered, PartialLiftedState } from './filters'; import { isFiltered, PartialLiftedState } from './filters';

View File

@ -4,15 +4,8 @@ import {
getActionsArray, getActionsArray,
getLocalFilter, getLocalFilter,
} from '@redux-devtools/utils'; } from '@redux-devtools/utils';
import throttle from 'lodash/throttle'; import { throttle } from 'lodash-es';
import { import { Action, ActionCreator, Dispatch, Reducer, StoreEnhancer } from 'redux';
Action,
ActionCreator,
Dispatch,
Reducer,
StoreEnhancer,
StoreEnhancerStoreCreator,
} from 'redux';
import Immutable from 'immutable'; import Immutable from 'immutable';
import { import {
EnhancedStore, EnhancedStore,

View File

@ -92,7 +92,7 @@ importers:
localforage: localforage:
specifier: ^1.10.0 specifier: ^1.10.0
version: 1.10.0 version: 1.10.0
lodash: lodash-es:
specifier: ^4.17.21 specifier: ^4.17.21
version: 4.17.21 version: 4.17.21
react: react:
@ -150,9 +150,9 @@ importers:
'@types/chrome': '@types/chrome':
specifier: ^0.0.269 specifier: ^0.0.269
version: 0.0.269 version: 0.0.269
'@types/lodash': '@types/lodash-es':
specifier: ^4.17.7 specifier: ^4.17.12
version: 4.17.7 version: 4.17.12
'@types/react': '@types/react':
specifier: ^18.3.3 specifier: ^18.3.3
version: 18.3.3 version: 18.3.3