gabe
gabe
DDeno
Created by Jasmine Boba'tea on 1/3/2025 in #help
What is the best way to get the full url that Deno.serve() is running on?
yes, the handler (second parameter to Deno.serve() ) is a function that receives 2 parameters: requestand info: - serve docs: https://docs.deno.com/api/deno/~/Deno.serve#function_serve_2 - ServeHandler type definition: https://docs.deno.com/api/deno/~/Deno.ServeHandler try this:
Deno.serve(
{ port: 1993, hostname: '0.0.0.0' },
(_req, info) => {
console.log(info);
return new Response("Hello, world");
}
);
Deno.serve(
{ port: 1993, hostname: '0.0.0.0' },
(_req, info) => {
console.log(info);
return new Response("Hello, world");
}
);
6 replies
DDeno
Created by 177177177 on 10/4/2022 in #help
sub sub domain on deno.dev
@isekusa wildcard subdomains are a paid feature (https://deno.com/deploy/pricing), and from the looks of it on the dashboard, they can only be applied to custom domains, not deno.dev. I would go on a limb and say that it's not possible today. Try asking on #deploy™ and see if someone from the Deno org answers with more context
4 replies