Deno

D

Deno

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

Join

'Deno.exit' is not allowed in this context.

Locally I can do in a nest project npm run build deno run -A .enviroment/deploy.ts ...
No description

WASM version of SWC.RC errors only in debug mode

NOTE: This is a bare bones example just to illustrate the problem: we aren't transpiling anything just getting the wasm to init. basic setup: - swc.ts:...

With Deno.serveHttp marked as deprecated is there a way to run an HTTP server off of a Deno.Conn?

I have a bit of weird use-case where I want to start a listener, accept the first TCP connection (and serve HTTP to it) and then reject all future TCP connections. I have the following code: ```ts const server = Deno.listen({...

Is this correct for Javascript?

https://github.com/tc39/proposal-change-array-by-copy This is my opinion about it: This kind of proposal are very harmful for JS/TS. What will we do? Duplicate every method that could create a new modified Array/Object?...

Finalization not working

I can't get the gc to run a destructor.. At first I thought that I'm making some kind of mistake here but I don't know where.. I was trying to make a Drop trait ```ts...

deno inside of a docker container

Despite installing it and confirming it inside I can't run deno in this container. Any idea why?
No description

Packaging deno packages to be used in an air-gapped environment

I work in an air-gapped environment, where I, as a user have no access to the internet. For development, we run JFrog Artifactory which has access to the internet via a proxy, which is effectively a registry (pypi, npm, dockerhub, nuget, etc) mirror. It virus scans artefacts on ingestion. This means I can still pip/npm install things off the internet to do development via artifactory....

FsWatcher.close() error : BadResource

Hi community 🙂 I have an error when i try to close watcher after it throw remove event on directory. Error : error: Uncaught (in promise) BadResource: Bad resource ID this._watcher.close()...

Cron BackoffSchedule 502

When testing the sample code from the Deno Deploy docs in the Deno playgroud, I'm getting a 502 bad gateway error. To reproduce: 1. Copy code from https://docs.deno.com/deploy/kv/manual/cron#retrying-failed-runs 2. Paste code to https://dash.deno.com/tutorial/tutorial-cron 3. Save and Deploy ...

i need help why isnt C:\Users\ollie\.deno\bin\deno.exe showing up?

for some reason, C:\Users\ollie.deno\bin\deno.exe isnt showing up i just made deno and i cant find it on mny pc

How To Add .done method for new Response();

Add a .done method to new Response() to ensure that the response was delivered to the client. function handler(_req) { const res = new Response(null, { headers }); ...

Deno + TypeScript

Hi, I am a newbie and I am learning to deploy TypeScript projects in Deno, but I keep getting errors. How to deal with it?
No description

Deno Bindgen

When attempting to follow the deno bindgen documentation I get errors about not being able to parse the cargo output or not being able to find symbols, I am basically following the example folder in the repo.
Is the deno_bindgen project ment to be installed locally as a cargo crate for the project so you can annotate the functions with deno_bindgen? Am I missing something in the documentation? If someone is knowledable about the crate I can post more error information....

Deno.enable not working

https://docs.deno.com/runtime/manual/references/vscode_deno/#deno-enabling-a-workspace In another project, I manually created (in VSC) the root folder .vscode and the file settings.json with the content { "deno.enable": true } and it worked. In a new project (in the same workspace), I tried this again but it does not work in the editor: Cannot find module 'jsr:@std/dotenv' or its corresponding type declarations.ts(2307) When trying to run, it works fine....

Deno + Jupyter

I want to learn to use deno in jupyter notebooks, so I have a whole bunch of questions. Note that my experience with jupyter as such is not extensive. * how to use deno fmt on my notebook's cells? * how to make plots with plotly.js? or for that matter, any plotting lib that isn't @observablehq/plot or vega-lite-api? * how to make an animated plot with any plotting lib?...

MySQL Parameters Not Working

Hi there! So, I'm currently trying to use mysql BUT the parameters aren't working. I've attached a screenshot of my code (easier than a code block, in this case) and of the MySQL query log. Any and all help would be appreciated! I'm sure I'm just being stupid and it's something really simple, but I just can't see what's wrong.
No description

Change color of console.logs from a worker

Hello, I'm trying to work with the NPM Package tmi.js and i tried converting it over to typescript and Deno APIs but the script is just too complicated and relies on too many NPM packages, so im wondering if theres a way just to change all of the colors of console.log() without doing so in the code of the module since im running it as a worker

regex pattern in rust

I need help with regex pattern making. lets say there are some files with .md but i should not match .skip.md Help me with this negations pattern....