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

Stop using deprecated search API from EPSG.io #15806

Merged
merged 1 commit into from May 7, 2024

Conversation

petrsloup
Copy link
Member

Summary

This PR updates a single example demonstrating map reprojection by full-text searching for coordinate systems.
The Coordinate system search API from EPSG.io is going to be deprecated soon and is replaced by the similar API from MapTiler Cloud. (That requires a free key, but the same key from other examples can be used here as well.)

The API is very similar, but some minor changes were required.

Note

Only the dynamic full-text search (and remote transformation API) is getting deprecated, the https://epsg.io/${code}.proj4 is still going to work as before, so this code does not require any change:

let epsgLookup = async function (code) {
const response = await fetch(`https://epsg.io/${code}.proj4`);
if (!response.ok) {
throw new Error(`Unexpected response from epsg.io: ${response.status}`);

Copy link

github-actions bot commented May 7, 2024

📦 Preview the website for this branch here: https://deploy-preview-15806--ol-site.netlify.app/.

Copy link
Member

@ahocevar ahocevar left a comment

Choose a reason for hiding this comment

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

Thanks, @petrsloup

@ahocevar ahocevar merged commit 13f9ca2 into openlayers:main May 7, 2024
8 checks passed
@petrsloup petrsloup deleted the epsgio_to_coordinatesapi branch May 8, 2024 05:49
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.

None yet

2 participants