invertase / dart_edge

Run Dart on the Edge - supporting Vercel & Cloudflare Workers (more coming soon).
https://docs.dartedge.dev
Apache License 2.0
324 stars 23 forks source link

upgrade to typings #55

Open MutantPiggieGolem1 opened 1 year ago

MutantPiggieGolem1 commented 1 year ago

This was in effect a basic replacement of js_bindings with typings Major Changes include:

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

Ehesp commented 1 year ago

@MutantPiggieGolem1 thanks a lot for this.

I've made some changes, primarily reverting the removal of the Request class, since we without it we're depending on the interop layer Request, which (for good reason) doesn't provide a strong type definitions as we'd like and could change at any time.

I have one issue left, the FetchEvent class changes you made wouldn't work, since it creates a circular reference to itself (so Dart thinks it's fixed, when in reality it is not). It seems as though the typings package does not provide the FetchEvent types. It's defined in the TypeScript types here but doesn't seem to be exported to Dart. An issue needs to be made over there (if you could make it, that'd be super useful) to bring it in.

However saying that, I'm not sure whether we actually need it for Dart Edge. It's an API of addEventListener, which we don't seemingly use since we generate the event listener code in JS land via the CLI. So we could get rid of it, as I assume no one is using it?

jodinathan commented 11 months ago

I've published a new version with bug fixes and WebWorker.

please do some tests and add issues in https://github.com/jodinathan/typings/issues if anything comes up

dshukertjr commented 10 months ago

Hi there,

Just checking here, but do we need additional changes to be made for this PR to be merged?

bigbenyayi commented 9 months ago

Any ideas when this PR will be merged? Dart Edge is none functional it doesn't even compile...

alaincruz06 commented 6 months ago

Strongly waiting for this PR to be merged or another release from the team. Can't compile more functions until this typings migration is done.

martijn00 commented 2 months ago

@Ehesp can you get the PRs on this project some attention? It would be great to merge some and get a new release!