Deno

D

Deno

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

Join

Webgl2 in Deno i.e. for unit testing

nodejs has this challenge that there is no way to run webgl2 (or webgpu), i.e. for unit testing. There is a solution for webgl1, through the use of https://github.com/stackgl/headless-gl. Is there a way to run webgl2 in deno, headless?

"A fetch response body was created during the test" when invoking a PUT request in a test?

I'm writing a Deno library for uploading files on IPFS. The code is very simple: ```ts...

Deno.Command

I'm looking to run a child_process with readline and spawn. I've tried following examples and such. Would it be better to use spawn from non:child_process? For std thread? ...

module not updating anymore

i have a module which is not updating anymore it seems to be stuck on version 1.5 i already have pushed several new tags and i also can see successfull deliveries on my github page but the module just does not update , i really dont want to spam the module space but if this problem gets not solved quickly i am forced to create another module which has the exact same content plus the new one... https://deno.land/x/handyhelpers@1.5...

Contributing doc is 404

Refer to https://deno.com/manual/contributing (it is a part of deno's PR template)

How to Extensions in JSRuntime ?

Here's my function to create rt fn get_js_runtime() -> deno_core::JsRuntime { let extensions = vec![deno_console::init_ops_and_esm()]; let js_runtime = deno_core::JsRuntime::new(...

Am I supposed to commit my vendor directory when deploying with the Github Action?

My deploy failed with the message "The deployment failed: import map not found at 'file:///src/vendor/import_map.json'". I didn't need to commit my vendor directory to do the Automatic deploy, am I supposed to commit it when using the Action?...

Where is the default/blank deploy.yml file?

According to this doc page, I should be redirected to a page with a default deploy.yml for me to add to my project. I've tried linking a couple of times, but haven't been redirected to that page. Can someone share the url where I can find it?...

peer tailwind support in fresh

Is there support for tailwind peers as described here in fresh? https://tailwindcss.com/docs/hover-focus-and-other-states I've uploaded a repo with code like so ```...

Deno+vite crashes on node dependency

Earlier today I was happy because everything worked on my m1 macbook. When I've returned home (arch) I got errors from latest deno... (I am running deno on the metal, but I will provide a way to reproduce it with docker:) ```Dockerfile FROM denoland/deno:1.38.3...

Jetbrains IDEA imports incompatible

I have deno.json file with a custom import... on vscode with deno's extension not have a trouble, but on IDEA not works. Deno compile fine, and works on deno deploy, but IDE is useless....
No description

question.. web push notifications having trouble with modules

Hi. I’m new to Deno. Overall I’ve been happy with is performance and how lightweight and secure it is. The place I’m having trouble is building a successful server with modules. For example, most of the imports I need to use aren’t available anymore. Here’s an example of the code I can’t get modules to import with: import { Application, Router } from 'https://deno.land/x/oak/mod.ts';...

Certain code prevents Deno from doing anything

Any time I try and use Deno with npm:zeromq@6.0.0-beta.19, running my code has absolutely no output whatsoever, even breaking console.log() at the beginning of the file. I've tried running with a debugger but I get no output there too. This is the module I'm trying to run, which wraps around the C library Libzmq under the hood. https://github.com/zeromq/zeromq.js ```ts...
Usage of zmq lib uncommented

Custom `401 Unauthorized` error page, similar to builtin `404 Not Found`?

How can I create a custom error page that is rendered by middleware in Fresh? The middleware handles authentication for incoming requests and if a request fails authentication, the middleware should generate a 401 Unauthorized response that includes the body of the custom error page.

Using `deno_emit` from Rust: building import graph

I'm trying to use deno_emit from Rust to bundle modules. I already evaluated these modules with deno_runtime, is there any way to extract and use the module graph and transpiled code that was already built during evaluation? Or perhaps reuse deno_core::ModuleLoader for deno_graph::source::Loader? I'm having a hard time figuring out how to use deno_emit and deno_graph from Rust, so I'm hoping there's an easier way to bundle code since I already evaluated the modules.

NPM Packages Usage on deno_core ?

Hello, I'm visiting from https://deno.com/blog/roll-your-own-javascript-runtime-pt2. Utilizing JSRuntime within Rust was fantastic. I encountered an issue when attempting to load npm packages/CDNs in JS code. The error message I received is: TypeError: Module loading is not supported; attempted to load: "https://dev.jspm.io/xxxx" from "(no referrer)"...

`deno.disablePaths` doesn't work

Hi in .vscode\settings.json I have this: ```json { "deno.disablePaths": ["**/kit", "./kit", "../kit", "/kit", "kit"],...
No description

What is the correct syntax to set the `compilerOptions.types` to use npm @types library

For example: As of now if I want my .ts files to have access to the npm:express packages @types/express I need to always reference in each file // @deno-types="npm:@types/express"...

Using "imports" in deno.json doesn't work in VS.code

* deno 1.38.3 * vs.code 1.84.2 * denoland.vscode-deno 3.28.0 I got rid of my import map and moved the "imports" directly into deno.json, as supported since 1.30.0....