Skip to content

Adds targets for the other environments #1062

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jul 19, 2021
Merged

Adds targets for the other environments #1062

merged 5 commits into from
Jul 19, 2021

Conversation

orta
Copy link
Contributor

@orta orta commented Jul 9, 2021

Adds support for deploying:

  • @types/webworker
  • @types/serviceworker
  • @types/audioworklet
  • @types/sharedworker

@types/sharedworker already exists and was removed from DT by me back in 3.9 - DefinitelyTyped/DefinitelyTyped#43366 - the deployment infra will see this and release this version as 0.0.30.

@orta
Copy link
Contributor Author

orta commented Jul 9, 2021

Going to give this the weekend for TS team members to give any feedback, will merge on Monday 👍🏻

readme: "./readmes/serviceworker.md",
files: [
{ from: "../generated/serviceworker.generated.d.ts", to: "index.d.ts" },
{ from: "../generated/serviceworker.iterable.generated.d.ts", to: "index.iterable.d.ts" },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While you are at it: how can index.iterable.d.ts be referenced? 👀 Should the step be added to readme?

Copy link
Contributor Author

@orta orta Jul 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hrm, I thought it would be automatically be included in all builds because it lives in @types and we read all the files in there. Haven't actually checked though.

Copy link
Contributor

@saschanaz saschanaz Jul 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Somehow it doesn't work like that in my environment (see there is no index.iterable.d.ts):

image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree, the build pipeline will probably need to add something like /// <reference path="..." /> to the index.dt.s

A user can probably get these imported into their globals via import "web/index.iterable" but that's weaksauce

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But that would mean packages will require es6+ 🤔

Copy link
Contributor Author

@orta orta Jul 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding /// <reference path="./index.iterable.d.ts" /> to the top of index.d.ts automatically includes it. I think this is a reasonable enough default if we document it as supporting ES6+

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, since it's probably time to concentrate on es6+ 😁

@orta orta merged commit d5ac135 into main Jul 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants