-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import map embedded in deno.json not supported #344
Comments
@uriva deno deploy doesn`t support npm specifiers yet |
Ok but is there some simple recipe to do it in this case? |
try cdns, it could work |
someone helped me (can see answer) - this was really not obvious to me as a beginner... thanks! |
actually, still doesn't work. maybe because deno deploy doesn't understand where my deno.json is? repo is uriva/portal |
I tried placing the deno.json near the index.ts and also in the root on both attempts I got
|
Thanks for reporting the issue. Unfortunately Deno Deploy doesn't currently support import map embedded in deno.json although it's been supported since Deno v1.30. We will be working on adding the support to Deploy. |
Duplicate of #314. |
No this issue is now not a duplicate of #314. The topic has changed to the lack of support for import map embedded in deno.json. I'm going to reopen it and to change the title to make it clear. |
Also hit this - using "import" in The fix is to create a separate import_map.json, and reference it via "importMap" key in Deno Deploy should work 1:1 with my local dev, especially with something that is recommended in the deno docs. small thing, but it's one of those tripping hazards that makes people go back to node |
We're aware that the inconsistency between CLI and Deploy is so annoying, and we're working on resolving it. |
This commit allows JSONC to be embedded in an eszip as an import map. This is primarily for deno's config file, which can be JSONC (e.g. `deno.jsonc`). Embedded JSONC data can then be retrieved by calling `get_import_map` method, which is a new method. Keep in mind that the existing similar method, `get_module`, will not return JSONC. This separation ensures that whatever returned from `get_module` is definitely a valid module, which may be useful when implementing support for dynamic import. Ideally eszip's serialization format should have a dedicated optional section for an import map so that we can treat import maps and modules differently. We can't do this while keeping v2 since this would break backward compatibility. ref denoland/deploy_feedback#344 ref denoland/fresh#1188
Import maps embedded in |
this is what I got, but locally deno does find the target
The text was updated successfully, but these errors were encountered: