From 7bad5ea26c6320411537371f1dcda267cc2b6821 Mon Sep 17 00:00:00 2001 From: Jeppe Reinhold Date: Sun, 21 Jul 2024 23:16:50 +0200 Subject: [PATCH] replace lodash-es usage with es-toolkit --- package.json | 1 - pnpm-lock.yaml | 8 -------- src/runtime/emit-code.ts | 2 +- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/package.json b/package.json index bfda38a..8d440e4 100644 --- a/package.json +++ b/package.json @@ -67,7 +67,6 @@ "dedent": "^1.5.3", "es-toolkit": "^1.13.1", "esrap": "^1.2.2", - "lodash-es": "^4.17.21", "magic-string": "^0.30.10", "svelte-ast-print": "0.2.3", "zimmerframe": "^1.1.2" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 21bdc49..165d7f0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -32,9 +32,6 @@ importers: esrap: specifier: ^1.2.2 version: 1.2.2 - lodash-es: - specifier: ^4.17.21 - version: 4.17.21 magic-string: specifier: ^0.30.10 version: 0.30.10 @@ -3971,9 +3968,6 @@ packages: resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} engines: {node: '>=10'} - lodash-es@4.17.21: - resolution: {integrity: sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==} - lodash.camelcase@4.3.0: resolution: {integrity: sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==} @@ -11282,8 +11276,6 @@ snapshots: dependencies: p-locate: 5.0.0 - lodash-es@4.17.21: {} - lodash.camelcase@4.3.0: {} lodash.chunk@4.2.0: {} diff --git a/src/runtime/emit-code.ts b/src/runtime/emit-code.ts index e9fa4c4..54a9627 100644 --- a/src/runtime/emit-code.ts +++ b/src/runtime/emit-code.ts @@ -2,7 +2,7 @@ import { SourceType, SNIPPET_RENDERED } from '@storybook/docs-tools'; import { addons } from '@storybook/preview-api'; import type { StoryObj } from '@storybook/svelte'; -import get from 'lodash-es/get'; +import { get } from 'es-toolkit/compat'; import type { ComponentProps } from 'svelte'; import type { EmptyObject } from 'type-fest';