Deno

D

Deno

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

Join

[React App Tutorial] Issue finding @oak & @tajpouria

Hey yall, While going through the react app tutorial I have come across this issue while adding the backend - from section Add a Backend running
deno add jsr:@oak/oak jsr:@tajpouria/cors
deno add jsr:@oak/oak jsr:@tajpouria/cors
...

Workspaces breaking imports in Neovim

Hello, I'm trying to incorporate Deno into a monorepo. I have workspaces set in my root deno.json, and some dependencies defined in deno.json for each of the workspaces. I'm able to run my code with the CLI just fine, but the lsp doesn't seem like it's able to find any of my dependencies, as every import line has the error "Relative import path "[...]" not prefixed with / or ./ or ../ deno (import-prefix-missing)" If I open up the same code in VSCode with the deno plugin, I don't get any errors, so it seems specific to denols/my config. Does anyone know how I can fix this?...

Deno + TSServer weirdness

I'm new to Deno and have had a frustrating introduction to Deno. When I would import libraries into my Deno project, any nested types that weren't explicitly imported lost their typing, resulting in an any type. This ended up only applying to a small portion of my code, but it was enough to drive me nuts. To be more specific, I'm building a Hono app to deploy on Deno Deploy, and the context parameter is showing up as any type. I had a hunch that maybe Deno LSP & TSServer were interacting in some way and decided to disable TSServer, and the correct type showed up! I was able to get types working correctly without completely disabling TSServer by adding "typescript.disableAutomaticTypeAcquisition": true,...

Sponsoring / freebies for Node.JS Vienna Group

Hey community we just reactivated the vienna nodejs meetup group and are in search for sponsors and freebies for the next upcoming events. Bun & Deno will be definitly also on the roadmap of future talks and it would be awesome to get some support here. I am grateful for any help 😉 cheers https://www.meetup.com/nodejs-vienna/

How to import library in Edge Function ?

Hey Good afternoon ! I would like to export my function in an edge function to execute it in the back. I'm using supabase and I installed deno to do that. I would like to import my libraries like my initial function but deno it's different......

Create a desktop app using Deno + Svelte with Compile

Hello guys! I'm new to Deno and I have some questions and would love your help figuring some things out! At the moment I have an desktop app using node + sveltekit + electron, and I since I saw that Deno was able to generate executables maybe I could just use Deno with sveltekit The closest thing I found was https://github.com/bluwy/create-vite-extra/tree/master/template-deno-svelte...

Settings an icon with deno --compile

Hello there 👋 , I'm trying to build an exe and specify an icon for it, with Deno 2, using deno compile --icon LogoAstro.ico main.ts as mentioned in the documentation (https://docs.deno.com/runtime/reference/cli/compiler/). And it is just totally ignored : the build succeed but it use the default window application icon. The file is a fairly light .ico image. So, is there some hidden specification for it ? Or is it a known issue ?...
No description

Deno `install.sh` script stucks at `.zshrc` backup step

While installing deno, the installation gets stuck at zshrc backup step. On first try had to kill the terminal process. But on the second time the installation succeeded after pressing Return key. Also the loader seems to be broken for that step...

Node:net capability problem?

I try to run my nestjs project on Deno 2.0.1, but it run out with the error below, but with Deno 2.0.0, there is no error, what happened? ``` [Nest] 1283 - 10/17/2024, 9:48:01 AM ERROR [ExceptionHandler] Cannot read properties of undefined (reading 'setNoDelay') TypeError: Cannot read properties of undefined (reading 'setNoDelay') at TCP.setNoDelay (ext:deno_node/internal_binding/tcp_wrap.ts:229:28)...

Adding libraries/modules?

Question I mean this in the most earnest, sincere, and curious way: should I be able to build a client side (Vite/React/TypeScript) and a server side (Hono) all with Deno and absolutely no Bun or npm? I think my learning curve-issue is that I'm not entirely sure how to add everything I need and want. I'm willing to take the time to learn but right out of the gate it's so different from npm or bun (or at least it currently feels like it is) that it feels more time consuming....

how to specify lint rules in deno.json?

hello. how can i specify the deno lint rules inside the deno.json file? if that is not possible, and they can only be passed via the cli, is there some other way to specify multiple of them in a single command? i would prefer not to write 105 flags....

What does deno lint do, if not type check?

Maybe I'm misunderstanding this, but I see in my IDE that there's a type problem. If I run deno lint on that directory, I'd expect it to complain about it, but it doesn't. See screenshot. Also, this is my attempt at adding Deno 2 to a project, and seenig what I can remove. I expected to be able to remove eslint and tsc type check, but doesn't seem like I can, unless I'm misunderstanding.
No description

Setting up Deno 2.0 with Fresh and TypeORM

I am trying to setup my first deno project ever using Fresh and TypeORM. I have setup 2 files A data.ts ```js...

Is there a way to use tsserver instead of deno lsp in VSCode?

Deno LSP lacks features. Is there a way to configure tsserver to work with deno?

Tools to shrink the output of deno compile?

Are there any tools to decrease the filesize of a deno compiled executable? I care primarily about Windows, but am interested in hearing about Linux options, too.

Deno add from different sources (like JSR) doesn't works?

Hi, I'm new with Deno. The problem is: I copy-paste this code deno add jsr:@oak/oak jsr:@tajpouria/cors and deno search it from npm and not jsr, it gives me the error error: npm package '@jsr/oak__oak' does not exist. why?...

deno compile next.js as standalone executable

Hello, Is it possible to compile a next.js project as a standalone executable file using deno's compile command? If so, how could I go about accomplishing this?...

vite + react

I'm following along the deno react tutorial, running deno add jsr:@oak/oak jsr:@tajpouria/cors returns Add jsr:@oak/oak@17.1.0 Add jsr:@tajpouria/cors@1.2.1 error: npm package '@jsr/oak__oak' does not exist....

Deno Vscode type checking randomly gets wrong types for discord.js EmbedBuilder

```ts export class EmbedBuilder extends BuildersEmbed { public constructor(data?: EmbedData | APIEmbed); public override setColor(color: ColorResolvable | null): this; public static from(other: JSONEncodable<APIEmbed> | APIEmbed): EmbedBuilder;...

`deno add` does not support the --cert option and does not use `$DENO_CERT`

I'm on zsh and use a custom registry in my .npmrc, and deno add runs into cert problems. When I add my organizations custom cert file to other deno commands, it works. However, deno add does not have this option, and seems to not use $DENO_CERT. How can I solve this problem? Help is appreciated....
Next