Skip to content
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

TypeScript definitions issues for XxxImageryProvider #8901

Closed
dave3068 opened this issue Jun 3, 2020 · 2 comments
Closed

TypeScript definitions issues for XxxImageryProvider #8901

dave3068 opened this issue Jun 3, 2020 · 2 comments

Comments

@dave3068
Copy link

dave3068 commented Jun 3, 2020

Regard the new version 1.70 which should officially support TypeScript,

All of the XxxImageryProvider not extends from ImageryProvider .

but the interface which use ImageryProvider is require an ImageryProvider parameter.
et: ImageryLayerCollection.addImageryProvider(...)

viewer.scene.imageryLayers.addImageryProvider(new TileCoordinatesImageryProvider({}));

This will got an error:

TS2345: Argument of type 'TileCoordinatesImageryProvider' is not assignable to parameter of type 'ImageryProvider'.

@mramato
Copy link
Contributor

mramato commented Jun 3, 2020

Thanks @dave3068 this was a last minute oversight when multiple PRs slightly overlapped each other. I'm going to open a pull request today to address it and am also looking at putting a small TypeScript smokescreen in place to prevent them from happening again.

We will most likely do a 1.70.1 patch release of Cesium to address this and other small TS issues that the community has found.

Thanks again for taking the time to let us know!

@hpinkos
Copy link
Contributor

hpinkos commented Jun 12, 2020

Fixed in #8908

@hpinkos hpinkos closed this as completed Jun 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants