Deno

D

Deno

Chat about Deno, a modern runtime for JavaScript and TypeScript.

Join

No deno install --prod ?

How to install package.json dependencies without the devDependencies (for production) ?

Getting bare specifier error | fresh and Deno workspace

When we use island of fresh with deno workspace we are getting bare specifier issue
specifier was a bare specifier, but was not remapped to anything by importMap.
specifier was a bare specifier, but was not remapped to anything by importMap.
...

Strange error when running Deno kubernetes container on only 1 node (out of my 3)

Recently migrated from Node.js to Deno. Works extremely well, except for this. I keep getting this strange error on one of my kubernetes containers on only 1 of my nodes when I try to run Deno. The error states: exec /tini: input/output error. I have zero idea how to fix it. Deno works fine on all of my other nodes, except for this one. They are all the same model mini pc, and should have the same configuration regarding OS, packages, and such. Can someone help me please? Thank you for your time and have a nice day....

A guide for js library maintainer

I just read the Deno 2 release blog, and it really got me excited about joining this ecosystem! And as a library maintainer, I’d love to know the recommended guidelines. For instance, if I want to deliver a library, it seems like I should write it in the Node.js (npm) style since Deno is compatible with Node, but not the other way around. However, this might not be great news for the Deno ecosystem and its future development. We could also suggest that maintainers publish to both npm and JSR, bu...

2.0 node_modules directory approach breaks when using private npm packages.

For some reason Deno 1.0 wasn't able to directly install private npm packages when using deno add. An alternative solution using .npmrc configuration files and enabling nodeModulesDir inside deno.json made it simpler as you would only need to deno cache <entrypoint.ts> to download your private npm package to the projects node_modules directory. If such package is not present at that time inside the directory the deno compile command would fail when building container images. This is why node_modules/ is needed. However, Deno 2.0 changed this and now, no matter what approach you take, you end up with a container constantly erroring out saying:...

ORM

I can't use prisma orm or sequelize orm with deno 2.0. I always have errors when I try to use it. The main problem with prisma, that I can't get generated types. I know that I can use preview feature for that, but it's unstable and I want to use something stable for my projects. Sequalize CLI doesn't work, I even don't know why, cuz the message isn't clear, look
Uncaught TypeError: Cannot read properties of undefined (reading 'getSequelize')
Uncaught TypeError: Cannot read properties of undefined (reading 'getSequelize')
...

Run npm publish

How can I run npm publish with Deno2?

"Too many open files" running an Astro app with Deno 2.0

Hi all, I just tried to run a (fairly small) Astro app in Deno 2.0 by seeing if it could be as simple as: deno install followed by deno run dev. It looks like it's starting up as normal (it shows the usual "astro v4.15.12 ready in 351 ms" and the URLs it's listening on) but then dies with the following message: ``` 14:21:11 watching for file changes... error: Uncaught Error: Too many open files (os error 24) at new FsWatcher (ext:runtime/40_fs_events.js:24:17)...

Build v2 in Amazon Linux 2023

I've been trying to build Deno v2 for a couple days but I'm not clear on what the minimum expected versions are, and when I think I have the version constraints satisfied there appear to be errors in the dependencies every time

Guidance in testing new publish flag

Hey! Not sure if this is the correct place to ask contribution questions but i'll give it a go! I have been working on my first contribution to the Deno project, which is the following issue I found in the issue tracker: https://github.com/denoland/deno/issues/22663. Here's a short rundown of what i've done so far: 1. Added the override_version field to the PublishFlags struct. 2. Added the --override-version argument to the publish_subcommand function. 3. Updated publish_parse function to also parse the override_version flag 3. Updated the publish function to apply the override version to the publish_configs if provided....

Speed of compiling deno from source

Probably a dumb question but when building deno once getting towards the end (Compiling deno v2.0.0 (/build/source/cli)) it ends up being stuck on 2 threads, fairly low CPU usage, high memory usage, working a long time. Is that unavoidable, just linking or something, or can I improve things? (Platform: x86_64 linux but also curious about other platforms)...

Run Nest.js with Deno2.0

Hi, congrats for Deno2.0 release. Now I'm trying to run my Nest.js project with Deno2.0 But I'm a noob and do not know how.(I didn't totally understood Deno2.0 supports npm modules) What is the standard or official way to run nest with Deno2.0? Just wait for Nest team to support Deno2.0?...

Open stack frame source in editor, for transitive dependency

When an error occurs in one of my transitive dependencies, I see a stack frame in my terminal that looks like this:
error: Module not found "https://glfw-binaries.deno.dev/3.4.0-patch1/glfw3_darwin.js".
at https://deno.land/x/dwm@0.3.2/src/platform/glfw/ffi.ts:2:20
error: Module not found "https://glfw-binaries.deno.dev/3.4.0-patch1/glfw3_darwin.js".
at https://deno.land/x/dwm@0.3.2/src/platform/glfw/ffi.ts:2:20
...

How to use set_internal_field of rusty v8?

After checking the process demo it seems that set_internal_field_count was called, but no actual value was set. So I'm wondering 1. is it possible to use this feature in rusty_v8? 2. In the cpp example SetNativeDataProperty & SetHandler(NamedPropertyHandlerConfiguration(MapGet, MapSet)) were used. Is it possible to do the same in rusty_v8?...

How to publish in JSR a library with workspaces?

I'm developing a hooks library from preact and react which a have a "common"/core library. I want to know how to publish the preact and react library in jsr.

Type resolution for modules imported with `npm:` specifier

moved from here: https://discord.com/channels/684898665143206084/684898665151594506/1292948811643224136 if i'm importing something from npm with an npm: specifier (i.e. npm:vite), if it has type definitions that reference another npm package (i.e. esbuild), is it a deno issue or a package issue if the types aren't resolved by deno (at least, the deno vscode extension)? tried with both npm:vite@5.4.8 as well as npm:vite@6.0.0-beta.2 and both of them don't load the types of esbuild when importing....

(Littledivy's SDL2 bindings) textures not loading properly

I'm using this script: ```typescript // main.ts import {WindowBuilder, EventType, Rect} from "sdl"; import img from "./utils/img.ts";...

Deno Add syntax?

It's clear that deno add jsr:@luca/cases works. But why doesn't deno add cliffy@v1.0.0-rc.7 error: cliffy@v1.0.0-rc.7 was not found in either jsr or npm. work?...

deno bindgen doesnt work

```rs // add.rs use deno_bindgen::deno_bindgen; #[deno_bindgen]...