Add exports config to help commonjs with nodenext#338
Add exports config to help commonjs with nodenext#338sebcrozet merged 1 commit intodimforge:masterfrom
Conversation
59d5f14 to
7abf2bf
Compare
|
Thank you! Let’s try this fix. If it still fails we’ll just remove the |
|
So I can confirm this works on the server but unfortunately this has now broken my client build. I dont think im running a too custom of a setup here so maybe you can give some guidance. I basically have a server / client game. I have a some basic classes that are shared between the server and the client so I dont need to implement everything twice. That basically means that I have a Now inside Note the Now inside my client and server classes (Client gets 3d Models assigned to it, and server gets custom movement logic) I basically do import SharedBall from '../shared/Base/Ball.ts'
export default class Ball extends SharedBall { }On the client however I AM using a bundler (vite) and it breaks there now. However I need to continue using Do you have a suggestion on how do handle server / client with shared classes with a physics world? Seems to have broken for other people too: #330 (comment) |
|
No problem at all @sebcrozet im more amazed at how broken the npm ecosystem is getting. (This isnt the first package to have these issues and it seems to be piling up). 18.2 is still broken for me with Module '"@dimforge/rapier3d-compat"' has no exported member Patching out |
I tested this with https://github.com/Vrixyz/rapierjs-no-bundler/tree/main/with_npm and https://github.com/mattvb91/rapierjs-module-bug/tree/master.