Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.
TypeScript accessibilityalternativecloudflarecloudflare-workersdesignfreefrontendopen-sourceradix-uireactremixweb-developmentwebflowwebsite-builderwebsite-developmentwebsiteswebstudio
build: Move rate-limit to cloudflare (#3710)
Ivan Starkov3cf1d2b16d59
diff --git a/apps/builder/middleware.js b/apps/builder/middleware.jsdeleted file mode 100644index 85bb549f2c..0000000000--- a/apps/builder/middleware.js+++ /dev/null@@ -1,467 +0,0 @@-/**- * To test middleware locally:- * ```shell- * # At project root:- * pnpx vercel link- * pnpx vercel dev- * ```- *- * OR- *- * ```shell- * # Link vercel project- * pnpm middleware:link- * # Initialize .env.preview- * pnpm middleware:env- * # Start middleware server- * pnpm middleware:dev- * ```- *- * OR- *- * ```shell- * pnpx vercel link- * pnpx vercel env pull --environment=preview ./.env.preview- * pnpm tsx watch --env-file=.env.preview ./middleware.js- * ```- */-import { Ratelimit } from "@upstash/ratelimit";-import { ipAddress, next as passthroughRaw } from "@vercel/edge";-import { createClient } from "@vercel/kv";-import { Hono } from "hono";-import { HTTPException } from "hono/http-exception";-import { env as envHono, getRuntimeKey } from "hono/adapter";-import { handle } from "hono/vercel";-import memoize from "memoize-one";-import { createCookieSessionStorage } from "@remix-run/cloudflare";--/**- * ----------------------------------------------------------------- * ---------------------======<<<Types>>>======--------------------- * ----------------------------------------------------------------- */--/**- * @typedef {object} Environment- * @property {string} KV_RATE_LIMIT_REST_API_TOKEN- * @property {string} KV_RATE_LIMIT_REST_API_URL- * @property {string} TRPC_SERVER_API_TOKEN- * @property {string} AUTH_SECRET- *- * @typedef {object} Variables- * @property {boolean} skipRateLimit- *- * @typedef {object} ContextEnv- * @property {Variables} Variables- */--/**- * ------------------------------------------------------------------- * ---------------------======<<<Utilities>>>======------------------- * ------------------------------------------------------------------- */--/**- * @param {import('hono').Context<ContextEnv>} req- * @returns {Promise<Response>}- */-let passthrough = async (req) => passthroughRaw();--/** @type {typeof envHono<Environment, import('hono').Context<ContextEnv>>} */-const env = (ctx) => envHono(ctx);--const getRateLimitMemoized = memoize(- /**- * @param {string} kvApiToken- * @param {string} kvUrl- */- (kvApiToken, kvUrl) => {- const rateLimiterCache = new Map();-- const kv = createClient({- token: kvApiToken,- url: kvUrl,- });-- const authorized = new Ratelimit({- redis: kv,- limiter: Ratelimit.slidingWindow(20, "5 s"),- ephemeralCache: rateLimiterCache,- prefix: "authorized",- });-- const unAuthorized = new Ratelimit({- redis: kv,- limiter: Ratelimit.slidingWindow(10, "5 s"),- ephemeralCache: rateLimiterCache,- prefix: "unauthorized",- });-- // No ephemeralCache for the AI endpoint- const ai = new Ratelimit({- redis: kv,- limiter: Ratelimit.slidingWindow(20, "1 m"),- prefix: "ai",- // Usually during AI request we need few requests available, small timeout here could break things- timeout: 60000,- });-- // For performance testing purposes- const perfTest = new Ratelimit({- redis: kv,- limiter: Ratelimit.slidingWindow(12000, "600 s"),- prefix: "test",- });-- const perfTestEphemeral = new Ratelimit({- redis: kv,- limiter: Ratelimit.slidingWindow(12000, "600 s"),- ephemeralCache: rateLimiterCache,- prefix: "ephemeral",- });-- return {- authorized,- unAuthorized,- ai,- perfTest,- perfTestEphemeral,- };- }-);--/** @param {import('hono').Context<ContextEnv>} ctx */-const getRateLimits = (ctx) => {- const { KV_RATE_LIMIT_REST_API_TOKEN, KV_RATE_LIMIT_REST_API_URL } = env(ctx);- if (KV_RATE_LIMIT_REST_API_TOKEN === undefined) {- throw new HTTPException(500, {- message: "KV_RATE_LIMIT_REST_API_TOKEN env variable is undefined",- });- }-- if (KV_RATE_LIMIT_REST_API_URL === undefined) {- throw new HTTPException(500, {- message: "KV_RATE_LIMIT_REST_API_URL env variable is undefined",- });- }-- return getRateLimitMemoized(- KV_RATE_LIMIT_REST_API_TOKEN,- KV_RATE_LIMIT_REST_API_URL- );-};--/**- * @todo: must be shared with 'apps/builder/app/services/cookie.server.ts' after ESM switch- */-const getSessionStorageMemozied = memoize(- /**- * @param {string} authSecret- */- (authSecret) =>- createCookieSessionStorage({- cookie: {- maxAge: 60 * 60 * 24 * 30,- name: "_session",- sameSite: "lax",- path: "/",- httpOnly: true,- secrets: authSecret ? [authSecret] : undefined,- secure: process.env.NODE_ENV === "production",- },- })-);--/** @param {import('hono').Context<ContextEnv>} ctx */-const getSessionStorage = (ctx) => {- const { AUTH_SECRET } = env(ctx);-- if (AUTH_SECRET === undefined) {- throw new HTTPException(500, {- message: "AUTH_SECRET env variable is undefined",- });- }-- return getSessionStorageMemozied(AUTH_SECRET);-};--/**- * @param {import('hono').Context<ContextEnv>} ctx- */-const getUserId = async (ctx) => {- const sessionStorage = getSessionStorage(ctx);- const { data } = await sessionStorage.getSession(ctx.req.header("Cookie"));- return data.user?.id;-};--/**- * @param {import('hono').Context<ContextEnv>} ctx- * @param {keyof ReturnType<typeof getRateLimits>} ratelimitName- * @param {string} key- */-const checkRateLimit = async (ctx, ratelimitName, key) => {- const rateLimits = getRateLimits(ctx);- const ratelimit = rateLimits[ratelimitName];-- const { success, pending, limit, reset, remaining } =- await ratelimit.limit(key);-- if (getRuntimeKey() !== "node") {- try {- ctx.executionCtx.waitUntil(pending);- } catch {- /**/- }- }-- if (success === false) {- // eslint-disable-next-line no-console- console.warn(- `ratelimit triggered: [${ratelimitName}] limit=${limit}, reset=${reset}, remaining=${remaining} key=${key}`- );-- throw new HTTPException(429, {- res: ctx.json(- {- error: {- message: `ratelimit triggered: [${ratelimitName}] limit=${limit}, reset=${reset}, remaining=${remaining}, key=${key}`,- code: 429,- meta: {- limit,- reset,- remaining,- ratelimitName,- },- },- },- 429- ),- });- }-};--/**- * ------------------------------------------------------------- * ---------------------======<<<App>>>======------------------- * ------------------------------------------------------------- */--/** @type {Hono<ContextEnv>} */-const app = new Hono();--// Debug route, to show current values, MUST BE ABOVE middlewares-app.get("/rate-limit/debug", async (ctx) => {- const rateLimits = getRateLimits(ctx);-- const aiKey = `${- (await getUserId(ctx)) ?? ipAddress(ctx.req) ?? "127.0.0.1"- }`;-- const userId = await getUserId(ctx);-- const ip = ipAddress(ctx.req) ?? "127.0.0.1";-- return ctx.json({- keys: {- aiKey,- userId,- ip,- },- unAuthorized: await rateLimits.unAuthorized.limit(ip),- authorized: await rateLimits.authorized.limit(userId),- ai: await rateLimits.ai.limit(aiKey),- });-});--// Debug route, to test the rate-limiting performance, MUST BE ABOVE middlewares-app.get("/rate-limit/test", async (ctx) => {- const rateLimits = getRateLimits(ctx);-- const aiKey = `${- (await getUserId(ctx)) ?? ipAddress(ctx.req) ?? "127.0.0.1"- }`;-- return ctx.json({- perfTest: await rateLimits.perfTest.limit(aiKey),- });-});--// Debug route, to test the rate-limiting performance with ephemeral cache, MUST BE ABOVE middlewares-app.get("/rate-limit/ephemeral-test", async (ctx) => {- const rateLimits = getRateLimits(ctx);-- const aiKey = `${- (await getUserId(ctx)) ?? ipAddress(ctx.req) ?? "127.0.0.1"- }`;-- return ctx.json({- perfTest: await rateLimits.perfTestEphemeral.limit(aiKey),- });-});--/**- * Check whether the request is for a static file; if so, bypass the rate-limiting mechanism.- */-app.use("*", async (ctx, next) => {- const skipRateLimit = ctx.get("skipRateLimit");- if (skipRateLimit) {- return next();- }-- const url = new URL(ctx.req.url);-- ctx.set(- "skipRateLimit",- url.pathname.startsWith("/asset/") ||- url.pathname.startsWith("/assets/") ||- url.pathname.endsWith(".ico")- );- return next();-});--/**- * Check whether the request is a service call; if so, bypass the rate-limiting mechanism.- */-app.use("*", async (ctx, next) => {- const skipRateLimit = ctx.get("skipRateLimit");- if (skipRateLimit) {- return next();- }-- const { TRPC_SERVER_API_TOKEN } = env(ctx);-- if (TRPC_SERVER_API_TOKEN === undefined) {- throw new HTTPException(500, {- message: "TRPC_SERVER_API_TOKEN env variable is undefined",- });- }-- const isServiceCall =- TRPC_SERVER_API_TOKEN !== undefined &&- ctx.req.header("Authorization") === TRPC_SERVER_API_TOKEN;-- ctx.set("skipRateLimit", isServiceCall);-- return next();-});--/**- * Rate limiting AI endpoint, max priority- */-app.use("/rest/ai/*", async (ctx, next) => {- const skipRateLimit = ctx.get("skipRateLimit");- if (skipRateLimit) {- return next();- }-- const aiKey = `${- (await getUserId(ctx)) ?? ipAddress(ctx.req) ?? "127.0.0.1"- }`;-- await checkRateLimit(ctx, "ai", aiKey);- ctx.set("skipRateLimit", true);-- return next();-});--/**- * Rate limiting authorized/unauthorized users- */-app.use("*", async (ctx, next) => {- const skipRateLimit = ctx.get("skipRateLimit");- if (skipRateLimit) {- return next();- }-- const userId = await getUserId(ctx);-- if (userId === undefined) {- await checkRateLimit(- ctx,- "unAuthorized",- ipAddress(ctx.req) ?? "127.0.0.1"- );- ctx.set("skipRateLimit", true);- return next();- }-- await checkRateLimit(ctx, "authorized", userId);-- ctx.set("skipRateLimit", true);-- return next();-});--app.notFound(async (ctx) => {- return passthrough(ctx);-});--app.onError(async (err, ctx) => {- if (err instanceof HTTPException) {- return err.getResponse();- }-- console.error(err.stack ?? err);-- return ctx.json({ cause: err.cause, message: err.message });-});--export default handle(app);--/**- * --------------------------------------------------------------------- * ---------------------======<<<Development>>>======------------------- * --------------------------------------------------------------------- */--if (process.env.NODE_ENV !== "production") {- if (getRuntimeKey() === "node") {- // To avoid vercel dev errors on build- const modulePath = "" + "@hono/node-server";- /** @type {Promise<import("@hono/node-server")>} */- const importedModule = import(modulePath);-- importedModule.then(({ serve }) => {- serve({ ...app, port: 3002 }, (info) => {- console.info(`Listening on http://localhost:${info.port}`);- });- });-- passthrough = async (ctx) => {- try {- const devUrl = new URL(ctx.req.url);- devUrl.port = "3000";-- const raw = ctx.req.raw;-- const req = new Request(devUrl, {- headers: raw.headers,- method: raw.method,- body: raw.body,- redirect: "manual",- // eslint-disable-next-line @typescript-eslint/ban-ts-comment- // @ts-ignore- duplex: "half",- });-- const res = await fetch(req);-- const responseHeaders = new Headers(res.headers);- responseHeaders.delete("content-encoding");-- return new Response(res.body, {- status: res.status,- statusText: res.statusText,- headers: responseHeaders,- });- } catch (error) {- throw new HTTPException(500, {- message:- error instanceof Error- ? `Middlewared dev fetch error ${error.message}`- : "Middlewared dev fetch error",- });- }- };- }-}diff --git a/apps/builder/package.json b/apps/builder/package.jsonindex b84c5e6390..429c283cea 100644--- a/apps/builder/package.json+++ b/apps/builder/package.json@@ -13,10 +13,7 @@"dev": "remix vite:dev","typecheck": "tsc --noEmit --emitDeclarationOnly false","test": "NODE_OPTIONS=--experimental-vm-modules jest",- "ci:migrate": "migrations migrate",- "middleware:link": "pnpx vercel link",- "middleware:env": "pnpx vercel env pull --environment=preview ./.env.preview",- "middleware:dev": "tsx watch --env-file=.env.preview ./middleware.js"+ "ci:migrate": "migrations migrate"},"dependencies": {"@atlaskit/pragmatic-drag-and-drop": "^1.1.11",@@ -50,9 +47,6 @@"@remix-run/server-runtime": "^2.10.0","@trpc/client": "^10.38.1","@trpc/server": "^10.38.1",- "@upstash/ratelimit": "^0.4.4",- "@vercel/edge": "^1.1.0",- "@vercel/kv": "^0.2.3","@vercel/remix": "2.9.2","@webstudio-is/ai": "workspace:*","@webstudio-is/asset-uploader": "workspace:*",@@ -87,14 +81,12 @@"detect-font": "^0.1.5","downshift": "^6.1.7","fast-deep-equal": "^3.1.3",- "hono": "^3.7.3","immer": "^10.0.3","immerhin": "^0.9.0","lexical": "^0.16.0","match-sorter": "^6.3.1","mdast-util-from-markdown": "^2.0.0","mdast-util-gfm": "^3.0.0",- "memoize-one": "^6.0.0","micromark-extension-gfm": "^3.0.0","nanoevents": "^8.0.0","nanoid": "^5.0.1",@@ -125,7 +117,6 @@"zod": "^3.22.4"},"devDependencies": {- "@hono/node-server": "^1.2.0","@jest/globals": "^29.7.0","@remix-run/dev": "^2.10.0","@testing-library/react-hooks": "^8.0.1",diff --git a/apps/builder/tsconfig.json b/apps/builder/tsconfig.jsonindex bea7d5128c..8537753492 100644--- a/apps/builder/tsconfig.json+++ b/apps/builder/tsconfig.json@@ -1,12 +1,6 @@{"extends": "@webstudio-is/tsconfig/base.json",- "include": [- "app",- "**/*.ts",- "**/*.tsx",- "../../@types/**/*.d.ts",- "./middleware.js"- ],+ "include": ["app", "**/*.ts", "**/*.tsx", "../../@types/**/*.d.ts"],"compilerOptions": {"types": ["@remix-run/node", "vite/client"],diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex dd23cb96a5..f86a454d59 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -196,15 +196,6 @@ importers:'@trpc/server':specifier: ^10.38.1version: 10.38.1- '@upstash/ratelimit':- specifier: ^0.4.4- version: 0.4.4- '@vercel/edge':- specifier: ^1.1.0- version: 1.1.0- '@vercel/kv':- specifier: ^0.2.3- version: 0.2.3'@vercel/remix':specifier: 2.9.2version: 2.9.2(@remix-run/[email protected](@remix-run/[email protected]([email protected]([email protected]))([email protected])([email protected]))(@remix-run/[email protected]([email protected]))(@types/[email protected])([email protected])([email protected](@types/[email protected]))([email protected](@cloudflare/[email protected])))(@remix-run/[email protected]([email protected]))(@remix-run/[email protected]([email protected]))([email protected]([email protected]))([email protected])@@ -307,9 +298,6 @@ importers:fast-deep-equal:specifier: ^3.1.3version: 3.1.3- hono:- specifier: ^3.7.3- version: 3.7.3immer:specifier: ^10.0.3version: 10.0.3@@ -328,9 +316,6 @@ importers:mdast-util-gfm:specifier: ^3.0.0version: 3.0.0- memoize-one:- specifier: ^6.0.0- version: 6.0.0micromark-extension-gfm:specifier: ^3.0.0version: 3.0.0@@ -416,9 +401,6 @@ importers:specifier: ^3.22.4version: 3.22.4devDependencies:- '@hono/node-server':- specifier: ^1.2.0- version: 1.2.0'@jest/globals':specifier: ^29.7.0version: 29.7.0@@ -3666,10 +3648,6 @@ packages:engines: {node: '>=6'}hasBin: true- '@hono/[email protected]':- resolution: {integrity: sha512-aHT8lDMLpd7ioXJ1/057+h+oE/k7rCOWmjklYDsE0jE4CoNB9XzG4f8dRHvw4s5HJFocaYDiGgYM/V0kYbQ0ww==}- engines: {node: '>=18.0.0'}-'@humanwhocodes/[email protected]':resolution: {integrity: sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg==}engines: {node: '>=10.10.0'}@@ -5547,19 +5525,6 @@ packages:resolution: {integrity: sha512-E0FbNzIk8TkVUF+kZGscDEmfYHps8/9qjvwJK6BjbbnxTaBPoSY9DQjsGWcCiD9pUKJt2tquNwADPiYzzkiKtA==}engines: {node: '>=14'}- '@upstash/[email protected]':- resolution: {integrity: sha512-cpPSR0XJAJs4Ddz9nq3tINlPS5aLfWVCqhhtHnXt4p7qr5+/Znlt1Es736poB/9rnl1hAHrOsOvVj46NEXcVqA==}- engines: {node: '>=16.0.0'}-- '@upstash/[email protected]':- resolution: {integrity: sha512-y3q6cNDdcRQ2MRPRf5UNWBN36IwnZ4kAEkGoH3i6OqdWwz4qlBxNsw4/Rpqn9h93+Nx1cqg5IOq7O2e2zMJY1w==}-- '@upstash/[email protected]':- resolution: {integrity: sha512-sXoJDoEqqik0HbrNE7yRWckOySEFsoBxfRdCgOqkc0w6py19ZZG50SpGkDDEUXSnBqP8VgGYXhWAiBpqxrt5oA==}-- '@upstash/[email protected]':- resolution: {integrity: sha512-7ec2eCMkVxZzuHNb+hPKonX4b/Pu0BdDeSBsEy+jKIqiweXzCs5Dpu9642vJgf57YnEsfwgXnQMVEataarvyeQ==}-'@vanilla-extract/[email protected]':resolution: {integrity: sha512-C188vUEYmw41yxg3QooTs8r1IdbDQQ2mH7L5RkORBnHx74QlmsNfqVmKwAVTgrlYt8JoRaWMtPfGm/Ql0BNQrA==}@@ -5572,13 +5537,6 @@ packages:'@vanilla-extract/[email protected]':resolution: {integrity: sha512-6YXeOEKYTA3UV+RC8DeAjFk+/okoNz/h88R+McnzA2zpaVqTR/Ep+vszkWYlGBcMNO7vEkqbq5nT/JMMvhi+tw==}- '@vercel/[email protected]':- resolution: {integrity: sha512-84H2EavY5Kul9Ef1DnTH0XEG5vChqcXjyqoRLVPjjZjLWw47sMapzXXQH09pybcshR+8AKqULGvFqPTWuRh3Rw==}-- '@vercel/[email protected]':- resolution: {integrity: sha512-Wq1+EsRBQmvLlcqCZeYVg1MAARWrnETgLe3Sy3UCqG+zg7LThpkt0YHZe1NN3Aj4IRmCKQamotWrLDdEx+ZB3w==}- engines: {node: '>=14.6'}-'@vercel/[email protected]':resolution: {integrity: sha512-3aTvWCS5U4bAkokhEVndcm9FyFv0/pW49b4qvcXIUyMi+vMNH4KTgPUbfeBDDtG7MLKFiQAYPUVr6rzc5ZtWkg==}engines: {node: '>=18.0.0'}@@ -7098,10 +7056,6 @@ packages:resolution: {integrity: sha512-nAxA0v8+vXSBDt3AnRUNjyRIQ0rD+ntpbAp4LnPkumc5M9yUbSMa4XDU9Q6etY4f1Wp4bNgvc1yjiZtsTTrSng==}- resolution: {integrity: sha512-BQHdLPXb30hQ9k+04byeSi4QMHk20U1GUq0nT5kGUCGZtxeYhAS7mUJ1wgjn4SCvgiw1rcc6oBOAlwJQ7jQymA==}- engines: {node: '>=16.0.0'}-resolution: {integrity: sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==}@@ -7423,9 +7377,6 @@ packages:resolution: {integrity: sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==}engines: {node: '>=0.10.0'}- resolution: {integrity: sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA==}-resolution: {integrity: sha512-PIeMbHqMt4DnUP3MA/Flc0HElYjMXArsw1qwJZcm9sqR8mq3l8NYizFMty0pWwE/tzIGH3EKK5+jes5mAr85yw==}@@ -7916,9 +7867,6 @@ packages:resolution: {integrity: sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==}engines: {node: '>= 0.6'}- resolution: {integrity: sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==}-resolution: {integrity: sha512-H6cBLgsi6vMWOcCpvVCdFFnl3kerEXbrYh9q+lY6VXvQSmM6CkmV08VOwT+WE2tzIEqRPFfAq3fm4v/UIW6mSA==}engines: {node: '>=18'}@@ -10016,9 +9964,6 @@ packages:resolution: {integrity: sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg==}engines: {node: '>=12'}- resolution: {integrity: sha512-d67JP4dHSbm2TrpFj8AbO8DnL1JXL5J9u0Kq2xW6d0TFDbCA3Muhdt8orXC22utleTVj7Prqt82baN6RBvnEgw==}-resolution: {integrity: sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==}engines: {node: '>=12'}@@ -11760,8 +11705,6 @@ snapshots:protobufjs: 7.3.2yargs: 17.7.2- '@hono/[email protected]': {}-'@humanwhocodes/[email protected]':dependencies:'@humanwhocodes/object-schema': 2.0.3@@ -14497,30 +14440,6 @@ snapshots:'@unocss/core': 0.61.2magic-string: 0.30.10- '@upstash/[email protected]':- dependencies:- '@upstash/redis': 1.22.1- transitivePeerDependencies:- - encoding-- '@upstash/[email protected]':- dependencies:- '@upstash/core-analytics': 0.0.6- transitivePeerDependencies:- - encoding-- '@upstash/[email protected]':- dependencies:- isomorphic-fetch: 3.0.0- transitivePeerDependencies:- - encoding-- '@upstash/[email protected]':- dependencies:- isomorphic-fetch: 3.0.0- transitivePeerDependencies:- - encoding-'@vanilla-extract/[email protected]':dependencies:'@babel/core': 7.24.5@@ -16392,8 +16311,6 @@ snapshots:- [email protected]: {}-@@ -16678,13 +16595,6 @@ snapshots:- dependencies:- node-fetch: 2.6.9- whatwg-fetch: 3.6.19- transitivePeerDependencies:- - encoding-@@ -17526,8 +17436,6 @@ snapshots:- [email protected]: {}-dependencies:mimic-function: 5.0.1@@ -19926,8 +19834,6 @@ snapshots:dependencies:iconv-lite: 0.6.3- [email protected]: {}-