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

standard-minifier-js of Meteor.js remove Promise #4001

Open
rtalon83 opened this issue Apr 15, 2024 · 2 comments
Open

standard-minifier-js of Meteor.js remove Promise #4001

rtalon83 opened this issue Apr 15, 2024 · 2 comments

Comments

@rtalon83
Copy link

A Meteor.js v2.5.8 web application using MapLibre 4.1.2 to show a simple map in a dashboard. Simple mongo links and show differents layers. In development mode all is ok.
But, When is production mode the app not run.

dist/maplibre-gl.js has this functions:

image

Promise is changed for arbitrary variable/string, in this case 'n'

image

maplibre-gl-js version: 4.1.2

browser: Chrome 123.0.6312.123

Steps to Trigger Behavior

  1. Create a new package from Meteor.js adding maplibre-gl library
  2. Set this package in packages folder.
  3. Build in production mode
  4. Map is visible but the communications are broken.

Consider using the non-minified version for this demo to create better error messages.
E.g. <script src='https://unpkg.com/maplibre-gl@1.15.2/dist/maplibre-gl-dev.js'></script><link href='https://unpkg.com/maplibre-gl@1.15.2/dist/maplibre-gl.css' rel='stylesheet' />

See https://stackoverflow.com/help/mcve for guidelines on creating an effective example.
-->

Expected Behavior

Actual Behavior

@HarelM
Copy link
Member

HarelM commented Apr 15, 2024

It is not clear what the problem is and how to reproduce it.
This looks like a bad behavior of a minifier that didn't do its job well, I'm not sure how this is related to maplibre...?
I see the word promise in both:
https://unpkg.com/browse/maplibre-gl@4.1.2/dist/maplibre-gl-dev.js
and
https://unpkg.com/browse/maplibre-gl@4.1.2/dist/maplibre-gl.js

@rtalon83
Copy link
Author

Yes, is a bad behaviour of a minifier of Meteor.js, I don't know why...
I write this issue because perhaps someone else has experienced the same thing.
Thanks.

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

No branches or pull requests

2 participants