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

Remove direct access to import.meta #11511

Merged
merged 1 commit into from
Sep 12, 2023
Merged

Conversation

fredj
Copy link
Contributor

@fredj fredj commented Sep 8, 2023

I use webpack-dev-server with my application and after upgrading from version 1.108 to version 1.109 I have the following error:

WARNING in ./node_modules/@cesium/engine/Source/Core/buildModuleUrl.js 44:21-32
Critical dependency: Accessing import.meta directly is unsupported (only property access or destructuring is supported)"

The webpack documentation says that:

webpack does not support direct access to import.meta. Instead, you should access its properties or use destructuring assignment.

This PR changes the defined parameter and webpack is happy with that

@cesium-concierge
Copy link

Thanks for the pull request @fredj!

  • ✔️ Signed CLA found.
  • CHANGES.md was not updated.
    • If this change updates the public API in any way, please add a bullet point to CHANGES.md.
  • ❔ Unit tests were not updated.
    • Make sure you've updated tests to reflect your changes, added tests for any new code, and ran the code coverage tool.

Reviewers, don't forget to make sure that:

  • Cesium Viewer works.
  • Works in 2D/CV.

@ggetz
Copy link
Contributor

ggetz commented Sep 11, 2023

Thanks @fredj! Would you mind updating CHANGES.md with a summary of the fix?

@fredj fredj force-pushed the import_meta_webpack branch from 6c243d6 to db45f05 Compare September 12, 2023 12:42
@fredj
Copy link
Contributor Author

fredj commented Sep 12, 2023

Thanks @fredj! Would you mind updating CHANGES.md with a summary of the fix?

done

@ggetz ggetz merged commit 9686389 into CesiumGS:main Sep 12, 2023
@ggetz
Copy link
Contributor

ggetz commented Sep 12, 2023

Thanks again!

@fredj fredj deleted the import_meta_webpack branch September 12, 2023 13:52
ZakarFin added a commit to ZakarFin/oskari-frontend that referenced this pull request Nov 15, 2023
@na9da na9da mentioned this pull request Feb 10, 2025
7 tasks
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