Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Allow docs to build 3.0.0-pre #458

Merged
merged 5 commits into from
May 23, 2023
Merged

Conversation

birkskyum
Copy link
Member

@birkskyum birkskyum commented May 19, 2023

This is ready, but let's update to the full 3.0.0 when it's out, as this will bump the docs to 3.0.0-pre.6 (overwriting the 2.4.0 online).

Fixes #457

This PR updates the changes in classes in Pre.2 (touch handlers renamed) and Pre.4 (clearStorage tile cache removed) - and the tests accordingly

This PR also introduces a simple find/replace to remove the type-only import/export of all style spec types, which isn't supported in documentationjs at this point. The approach taken is virtually identical to the previous remove-assert.js script which was used to compensate for a lack of json type assertion support in documentationjs when node 18 was introduced:
https://github.com/maplibre/maplibre-gl-js/blob/ad566a6069e6597e26e3685e48bf41a1532858d3/src/index.ts#LL38C1-L39C1

@birkskyum birkskyum requested a review from HarelM May 19, 2023 16:17
return console.log(err);
}
var result = data.replace(
"export type * from '@maplibre/maplibre-gl-style-spec';",
Copy link
Contributor

Choose a reason for hiding this comment

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

While I understand why this was added, we'll need to find a solution for this in the future. If I understand correctly, all the types from the spec package will not be included in the docs. This isn't optional.
I'm not sure what is the current situation though.

Copy link
Member Author

@birkskyum birkskyum May 23, 2023

Choose a reason for hiding this comment

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

You are right. At present it's not an issue for the docs though, because non of these types are used here, but I that we should not have these find/replace type workarounds even for docs.

@birkskyum birkskyum merged commit d9734d5 into maplibre:main May 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't update docs
2 participants