Questions tagged [deno]

A secure runtime for JavaScript and TypeScript.

Deno is a simple, modern, and secure runtime for JavaScript and TypeScript that uses V8 and is built in Rust.

  • Secure by default. No file, network, or environment access, unless explicitly enabled.
  • Supports TypeScript out of the box.
  • Ships only a single executable file.
  • Has built-in utilities like a dependency inspector (deno info) and a code formatter (deno fmt).
  • Has a set of reviewed (audited) standard modules that are guaranteed to work with Deno deno.land/std
919 questions
-1
votes
1 answer

Deploy Deno to AWS Lightsail

Is there a any way to deploy deno to aws lightsail without using aws container registry. I couldn't find any resources on how to deploy the deno app to lightsail without using the aws container registry
-1
votes
2 answers

Importing http/server ends with 404 in deno

below file is named index.ts import { serve } from "https://deno.land/std@0.166.0/http/server.ts"; function handler(_req: Request): Response { return new Response("Hello, World!"); } console.log("Listening on…
wiero
  • 2,176
  • 1
  • 19
  • 28
-1
votes
1 answer

Get url parameters in Deno using Opine or other Deno Library

I'm using Deno and Opine to create an API, how to get the data from the parameters sent via the url Get method? It can be with Opine or another library. Parameters i want to get: access_token, refresh_token, token_type Here is an example…
Gouveia
  • 29
  • 6
-1
votes
1 answer

How to render static html as a string instead of Preact?

I know the Fresh framework is in its early stages of development and that by default comes with Preact for rendering anything. But also, I've heard that Fresh is meant to be framework agnostic. My eventual goal is to create a framework that competes…
-1
votes
2 answers

TypeError - Cannot read properties of undefined (reading 'name')

Basically I'm running into this error when trying to use UseCase class on Deno. [uncaught application error]: TypeError - Cannot read properties of undefined (reading 'getAppInfosUseCase') request: { url: "http://127.0.0.1:3030/", method: "GET",…
João Pedro
  • 9
  • 1
  • 4
-1
votes
1 answer

Is there any alternative to `for await ... of` for Deno.listen()

I am new to Deno. In my first step to build Deno simple HTTP server, I saw this on the documentation, It works pretty well: const server = Deno.listen({ port: 80 }) for await (const conn of server) { /* etc... */ } Why Deno documentation prefer…
thebluetropics
  • 82
  • 2
  • 10
-1
votes
1 answer

global serverless functions callable at specific locations

Is there a service like Deno Deploy or Cloudflare Workers that auto-deploys functions to many locations around the globe and lets developers address/call them at specific locations (not just let users reach the closest location)? This would…
Cetin Sert
  • 4,497
  • 5
  • 38
  • 76
-1
votes
1 answer

Received a ServerHelloDone handshake message while expecting [CertificateRequest]

I'm getting this error in fetch with Deno: Received a ServerHelloDone handshake message while expecting [CertificateRequest] I'm hitting a web api I don't control.
chovy
  • 72,281
  • 52
  • 227
  • 295
-1
votes
1 answer

How do I fix these typescript errors?

Type 'string' does not satisfy the constraint 'unknown[]': const query = db.prepareQuery( TS2707 [ERROR]: Generic type 'RouterContext' requires between 1 and 3 type arguments. { request, response, state }:…
chovy
  • 72,281
  • 52
  • 227
  • 295
-1
votes
1 answer

Deno Server doesn't go through the Internet

I built a simple Webserver with just the serve function from the std http module. It just redirects a request to a new URL: import { serve } from "https://deno.land/std@0.120.0/http/server.ts"; serve(req =>…
-1
votes
2 answers

page.hover() having no effect

Description Some buttons on my website change color on hover, however when using deno-puppeteer it would appear to be having no effect. Relevant code: import { puppeteer } from './deps.ts'; const browser = await puppeteer.launch(); const page =…
kemicofa ghost
  • 16,349
  • 8
  • 82
  • 131
-1
votes
1 answer

Is it possible to combine two pooledMap arrays in deno?

const pool = pooledMap(20, feeds, (url) => { return getWithXidel(url, '//item/link'); }); const pool2 = pooledMap(20, feedEntries, (url) => { return getWithXidel(url, "//entry/link[@rel='alternate']/@href"); }); for await (const data of pool)…
chovy
  • 72,281
  • 52
  • 227
  • 295
-1
votes
1 answer

How to use Dropbox v2 upload file API in deno?

I'm trying upload a file using the Dropbox api in deno. But i dont know how to do that, because there is no sdk for deno. I want to try using fecth but when I upload the file, it gives a "bad request" error.
Kin Kurnia
  • 23
  • 1
  • 6
-1
votes
1 answer

Deno -> How do I run the codes to run without errors?

I'd like to import from local Testing environment Deno v1.6.0 I've tried local import by Deno lang Local directory . └── src └── sample ├── hello_world.ts ├── httpRequest.ts ├── localExport │ └──…
KKK
  • 95
  • 7
-1
votes
1 answer

How do I deploy my Deno application to heroku which uses a postgresql database?

I have an application which I'd like to deploy to heroku. I have already created the application in heroku and added the deno buildpack. I have also set up the databse using psql and created the tables. Now the only problem is I don't know how to…
MatiasC
  • 27
  • 3