URL constructor in Deno 1.2
Bidek56 opened this issue · comments
Darek commented
In Deno 1.2, this simple code fails with Type 'URL' is not assignable to type 'string'.
import React from 'https://dev.jspm.io/react';
import pogo from 'https://deno.land/x/pogo/main.ts';
const server = pogo.server({ port : 3000 });
server.router.get('/', () => {
return <h1>Hello, world!</h1>;
});
server.start();
Definition of URL constructor has changed in 1.2 by PR and I think you need to upgrade your package. Thx
Adam Faur commented
Looked at this and created PR (#47) which seems to fix this.
More information available here: https://dev.to/srnv/deno-1-2-0-url-argument-type-solutions-37m0
Seth Holladay commented
Fixed in PR #47