diff --git a/.changeset/kind-stingrays-sniff.md b/.changeset/kind-stingrays-sniff.md new file mode 100644 index 000000000..b33899f98 --- /dev/null +++ b/.changeset/kind-stingrays-sniff.md @@ -0,0 +1,5 @@ +--- +"@crxjs/vite-plugin": patch +--- + +removing unnecessary v8 dependency diff --git a/packages/vite-plugin/src/node/helpers.ts b/packages/vite-plugin/src/node/helpers.ts index 9a953e294..1d086c6a5 100644 --- a/packages/vite-plugin/src/node/helpers.ts +++ b/packages/vite-plugin/src/node/helpers.ts @@ -2,7 +2,6 @@ import { simple } from 'acorn-walk' import { createHash as _hash } from 'crypto' import debug from 'debug' import { AcornNode, OutputBundle, PluginContext } from 'rollup' -import v8 from 'v8' import type { ManifestV3, WebAccessibleResourceById, @@ -17,10 +16,6 @@ import type { export const _debug = (id: string) => debug('crx').extend(id) -export const structuredClone = (obj: T): T => { - return v8.deserialize(v8.serialize(obj)) -} - export const hash = (data: string, length = 5): string => _hash('sha1') .update(data) diff --git a/packages/vite-plugin/src/node/plugin-manifest.ts b/packages/vite-plugin/src/node/plugin-manifest.ts index d6c838bf0..6313cc1bb 100644 --- a/packages/vite-plugin/src/node/plugin-manifest.ts +++ b/packages/vite-plugin/src/node/plugin-manifest.ts @@ -11,7 +11,6 @@ import { decodeManifest, encodeManifest, isString, - structuredClone, } from './helpers' import { ManifestV3 } from './manifest' import { basename, isAbsolute, join, relative } from './path'