How to override the version from a dependency of a project's dependency from npm

I'm currently using react-pdf as a dependency, react-pdf uses fontkit as a dependency, and fontkit uses the npm restructure library. restructure, on the other hand, broke fontkit, therefore I would like to replace the new restructure version with the old one, so I tried using Deno.json's imports map, and scopes as well.
"imports": {
"restructure": "npm:restructure@3.0.0"
}
"imports": {
"restructure": "npm:restructure@3.0.0"
}
"scopes": {
"fontkit@2.0.2": {
"restructure": "npm:restructure@3.0.0"
}
}
"scopes": {
"fontkit@2.0.2": {
"restructure": "npm:restructure@3.0.0"
}
}
None of them replaced the version. Given that, there's a way to do so?
L
Leokuma38d ago
I think your first attempt, without scopes, should work Delete your node_modules folder and deno.lock file and try to run your project again with that import
H
HylianComrade38d ago
there's no node_modules folder, and I deleted deno.lock file already
L
Leokuma38d ago
try adding the following to your deno.json so that it creates a node_modules folder: "vendor": true
H
HylianComrade38d ago
Hello @Leokuma , first, thanks for the help, unfortunately, I had no success, it has creatednode_modules, and vendor folders, but the problem persists, I also deleted deno.lock again. Follow an image of the recently generated deno.lock showing restructure on its latest version.
No description
H
HylianComrade38d ago
also on node_modules there's a folder with the lastet version 3.0.1 instead 3.0.0
H
HylianComrade38d ago
No description
L
Leokuma38d ago
Ok so I guess you can report your issue here: https://github.com/denoland/deno/issues/20868
GitHub
npm: specifiers ignore import map · Issue #20868 · denoland/deno
I'm running into a bug with Fresh when trying to switch over to npm: specifiers. When using both preact-render-to-string and preact Deno loads multiple copies of Preact. This breaks preact'...
More Posts
How to publish global types with JSR?I was trying to republish my npm package with JSR via npm jsr package. It all went well with one excCaching results from APIHi, I'm currently working on a project where I get data from an API (https://www.robotevents.com/apiINTERNAL_SERVER_ERROR_2 / 500 response codeSeveral clients concurrently reported INTERNAL_SERVER_ERROR_2 with a 500 error on requests to a deplMy site seems to be under attackI receive a large amount of request last night. Does this mean my site is under attack...?Deno drizzle-kit migrate:pgI don't know if its drizzle error or Deno error... I saw path resolution problem, it is said `C:UseDoes V8 engine eventloop/threading model conflict with rust?hi, I am trying to embed deno's rusty_v8 into rust application. I am confused about the eventloop/thHow installing Silverbullet on denoOn the officle website of silverbullet they say we can install silver bullet on deno but i dont knowimplementing swagger in deno typescript with deno_swagger_doc on deno.land. it throws error.error: Uncaught (in promise) Error: Cannot find module './isomorphic.node' var e = new Error("Cannnpm install -D equivalentI want to use drizzle-kit. `npm install -D drizzle-kit` but don't know how to get it work in Deno.Kill deno process treeHow would you kill a Deno process _tree_ as in, force kill of Deno process _and any of it's subproceWhat to do if they are attacking a project of mine?Hello!, Yesterday I suffered an attack on one of my projects, they made 6 million requests in a veryError Installing Deno using PowerShellHello, may I please ask for assistance in regards to installing Deno using PowerShell on VS Code. AnSvelte/SvelteKit support in 2024What’s your experience?Subprocesscan someone help me how do i get to show Hello world in my terminal by using Deno.Commands () using Problems using @apple/app-store-server-library, how do I debug?Hi, I'm attempting to build out the backend of an IOS app on Supabase and want to be able to verifyIs there an easy way to read tls certificate and key from a filesystem?I do the following: ```js if (Deno.env.has("TLS_CERT_PATH") && Deno.env.has("TLS_PKEY_PATH")) { co