From 99188054e80fc46c9b85fff2f11982cff9836d25 Mon Sep 17 00:00:00 2001 From: Nathan Bierema Date: Sat, 6 Apr 2024 22:16:49 -0400 Subject: [PATCH] Use lodash-es --- packages/map2tree/package.json | 4 ++-- packages/map2tree/src/index.ts | 4 +--- pnpm-lock.yaml | 8 ++++---- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/packages/map2tree/package.json b/packages/map2tree/package.json index c71227c8..7d5ab1fd 100755 --- a/packages/map2tree/package.json +++ b/packages/map2tree/package.json @@ -37,11 +37,11 @@ "prepublish": "pnpm run lint && pnpm run test" }, "dependencies": { - "lodash": "^4.17.21" + "lodash-es": "^4.17.21" }, "devDependencies": { "@types/jest": "^29.5.12", - "@types/lodash": "^4.17.0", + "@types/lodash-es": "^4.17.12", "@typescript-eslint/eslint-plugin": "^7.4.0", "@typescript-eslint/parser": "^7.4.0", "eslint": "^8.57.0", diff --git a/packages/map2tree/src/index.ts b/packages/map2tree/src/index.ts index 74e231fb..322379e5 100644 --- a/packages/map2tree/src/index.ts +++ b/packages/map2tree/src/index.ts @@ -1,6 +1,4 @@ -import isArray from 'lodash/isArray'; -import isPlainObject from 'lodash/isPlainObject'; -import mapValues from 'lodash/mapValues'; +import { isArray, isPlainObject, mapValues } from 'lodash-es'; export interface Node { name: string; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index da42071d..3ac0e9fa 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -374,16 +374,16 @@ importers: packages/map2tree: dependencies: - lodash: + lodash-es: specifier: ^4.17.21 version: 4.17.21 devDependencies: '@types/jest': specifier: ^29.5.12 version: 29.5.12 - '@types/lodash': - specifier: ^4.17.0 - version: 4.17.0 + '@types/lodash-es': + specifier: ^4.17.12 + version: 4.17.12 '@typescript-eslint/eslint-plugin': specifier: ^7.4.0 version: 7.4.0(@typescript-eslint/parser@7.4.0)(eslint@8.57.0)(typescript@5.3.3)