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

JoltPhysics/RapierPhysics: Fix some warning messages #29315

Merged
merged 1 commit into from
Sep 4, 2024
Merged

JoltPhysics/RapierPhysics: Fix some warning messages #29315

merged 1 commit into from
Sep 4, 2024

Conversation

puxiao
Copy link
Contributor

@puxiao puxiao commented Sep 4, 2024

If you use webpack/rspack, you will receive a warning message like this:

Module parse warning:
  ╰─▶   ⚠ Critical dependency: the request of a dependency is an expression
          ╭─[41:30]
       39 │     if (RAPIER === null) {
       40 │
       41 │         RAPIER = await import(RAPIER_PATH);
          ·                               ────────────
       42 │         await RAPIER.init();
       43 │
          ╰────

Critical dependency: the request of a dependency is an expression

Therefore we cannot use a constant directly.

This warning can be resolved by using template strings.

@Mugen87 Mugen87 added this to the r169 milestone Sep 4, 2024
@Mugen87 Mugen87 merged commit 7ff45b0 into mrdoob:dev Sep 4, 2024
11 checks passed
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.

2 participants