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

[feat] expose version identifiers #1459

Closed
wants to merge 1 commit into from

Conversation

Pessimistress
Copy link
Contributor

@Pessimistress Pessimistress commented Aug 10, 2022

Restore version identifiers that were removed in v2.0

After this PR it is possible to get the package version via

import {version} from 'maplibre-gl';

Or with a Map instance:

map.version

See discussion in #1426

Launch Checklist

  • Confirm your changes do not include backports from Mapbox projects (unless with compliant license) - if you are not sure about this, please ask!
  • Briefly describe the changes in this PR.
  • Write tests for all new functionality.
  • Document any changes to public APIs.
  • Manually test the debug page.
  • Suggest a changelog category: bug/feature/docs/etc. or "skip changelog".
  • Add an entry inside this element for inclusion in the maplibre-gl-js changelog: <changelog></changelog>.

@HarelM
Copy link
Collaborator

HarelM commented Aug 10, 2022

Can you please add a test and a change log entry?
I think the 1.x branch had a test for that, that I might have removed, part of the build tests maybe...?

@github-actions
Copy link
Contributor

Bundle size report:

Size Change: +35 B
Total Size Before: 203 kB
Total Size After: 203 kB

Output file Before After Change
maplibre-gl.js 193 kB 193 kB +35 B
maplibre-gl.css 9.65 kB 9.65 kB 0 B
ℹ️ View Details No major changes

@birkskyum birkskyum mentioned this pull request Aug 13, 2022
@birkskyum
Copy link
Member

birkskyum commented Aug 13, 2022

Thank you for looking into this @Pessimistress. I figured out how to do this with typescript, without any rollup replace, and took the liberty to add the unit tests and changelog entry in this pr to get the ball rolling ( #1471 ).

@HarelM HarelM closed this Aug 13, 2022
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.

3 participants