Deno

D

Deno

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

Join

Memory leak in Deno.serve?

i have simple proxy server like this and it has memory leak issue which i have no idea how to tackle: https://gist.github.com/pakastin/503dcbcd141e2895a3d863253483c831

PEM Base64 Error while using mineflayer NPM Package

Hello. I am interested in using Deno to build a Minecraft player bot. I used the minelayer package and the Deno runtime. I wrote simple code that should log in to the player using Microsoft authentication. I am using Deno version 2.0.3, which is running on aarch64 Linux. I am also running mineflayer version 4.23.0....

Deno 2 + StencilJS: JSX Support

Hello! I'm having a few compatibilitiy issues with JSX in Deno 2, and I find myself having to fill out a jsx.d.ts with IntrinsicElements, Element, etc. How can I work around this?...

Default imports not working

I have an import like this:
import Stumper from "stumper";
import Stumper from "stumper";
I can't call any of the methods that exist on the default export. The Stumper object contains all of the exports from the entire library. I have the ability to use Stumper.default but I feel like that should not be necessary....

Uncaught Error: The handle is invalid

Hi... So I've been using npm's package called http-server to simply serve my public folder during my development phase. I run the following code:...

Error occurs when using React third-party component library

I want to use react-phone-number-input component in my project, but it gives error when I incorporate the component in my code. Picture 1 is the error it gives in browser and picture 2 is the error it gives in terminal. I wonder if anyone knows what's going on here or knows how to properly include third-party component library in the project? I created a small project to reproduce the error I got just for referrence: https://github.com/MingdaMa/fresh-react-third-party-library...
No description

Is there a way to run a command from a package in a workspace?

Something like: deno task server:check which would run the task "check" in the "server" package in my workspace.

INTERNAL_SERVER_ERROR_3

Will my server stop crashing with this error if I upgrade to a paid subscription? It's very frustrating for me and visitors to my website.

Include DLL files in deno compile

I'm currently building a CLI application with Deno that I want to compile into a standalone executable which uses FFI. I learned about deno compile, but I'm also stuck on how to include the DLLs that are used via FFI in my output binary. I don't want to include the DLLs separately after the binary is built, but I want to be able to ship a single binary. For example, nexe.js allows users to add static files under resources https://github.com/nexe/nexe?tab=readme-ov-file#resources...

Stencil JS in Deno 2?

Hello! I found this http://stencil.docschina.org/docs/deno/ but I don't feel comfortable downloading install scripts over HTTP. Does someone have another source?...

permission denied error when running deno install inside dockerfile

Hi there, I'm in the process of trying to migrate my node app to deno, as I was really impressed with the recent deno 2 announcement I have the following dockerfile, slightly modified from the example. ```Dockerfile FROM denoland/deno:2.0.3 set DENO_DIR to avoid conflicts with google cloud...

Running Fresh app on Windows with pm2

I'm trying to run a fresh project in a production environment (windows server) but for some reason whenever I run deno via pm2 it panics with a "The handle is invalid (OS Error 6)" message when I try to run it. I was also able to reproduce this on a regular windows 11 install. Interestingly I'm unable to reproduce this on a mac device which I used to develop the website. Is there some sort of config setting I need to enable for pm2 other than specifying deno as the interpreter? I'm using deno 2.0.3...

error on new Fresh deno project: error: unexpected argument '--allow-import' found

when i create a new Fresh project following the documentation i found this error : error: unexpected argument '--allow-import' found tip: to pass '--allow-import' as a value, use '-- --allow-import'...
No description

Deno cron timeout

I've got an app running on Deno deploy with a cron that triggers each two days, i noticed that after 6 ~ 8 minutes the cron interrupts the task and marks it as successful even if it didn't finish, i'm looking around for info if the Deno cron functionality got some timeout config and trying to understand why it's happening, the cron should run for like ~20 minutes.

Running test

Hey there, I am building a CLI and want to use Deno's test. However, in my VSCode the test runs successfully whereas when running deno test it doesn't. I have no idea which command VS Code is running (see image). Here is my function, i wanna test (btw. running deno run returns the right profiles): ...
No description

window install problem

Windows PowerShell Copyright (C) Microsoft Corporation. All rights reserved. Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows ...

Vite plugin's global variables are `undefined` when using Deno

Anyone run across this before? Running Deno 2 and Vite 6beta. I built a third-party Vite plugin, and now I'm testing it in a "native" Deno project (deno.json, not package.json, etc). However, all of the packages and dependencies are from npm. My Vite plugin defines a global like so. ```js ......

`deno compile` executable not working with cross-platforms

I have a basic app (frontend using vite and backend using oak) which upon a button click displays a message from the backend. This app is working totally fine on my personal laptop having Ubuntu (24.04.1 LTS), after running deno compile -A --output linux_app main.js, and then running ./linux_app to see my app running on http://localhost:8000. I'm using the useState hook - import { useState } from "react";, hence node_modules 's existence being there in my project. The issue arises when I compile the app to a Windows executable by specifying --target x86_64-pc-windows-msvc. I get the following warning: Warning The node_modules directory may be incompatible with the target system. ...

Http Patch request body does appears to not get parsed into json correctly

I am trying to use a nextJS app written for node to be used with deno , and I encounted this issue. I showcase in the images bellow - basically a http patch endpoint in nextJS - receiving a request and then decoding it It always returns undefined in deno while it works as expected in node and bun Any suggestion as to what i could look into / change to fix it? ```ts...
No description