matter-collision-events icon indicating copy to clipboard operation
matter-collision-events copied to clipboard

matter-tools should be a devDependency

Open getkey opened this issue 5 years ago • 2 comments

Since matter-tools is only used is the demo, it should be a devDependency.

Currently, when the matter-collision-events package is installed it will pull along matter-tools and all its dependencies. This is suboptimal because it results in a bigger node_modules directory and some of matter-tools dependencies take ages to get built cough node-sass cough.

Also, the node-sass that matter-tools uses' build process fails with Node.js 12 at the moment, so matter-collision-events can't be used in a Node.js 12 environment. Of course this issue also needs to be addressed separately, but at least it would not impact matter-collision-events users.

getkey avatar Apr 26 '19 13:04 getkey

Update on this issue, node-sass still cannot be built on Node 15, and it makes this project unusable. it is because of this dependency tree:

matter-collision-events > matter-tools > dat.gui > sassify > node-sass

matter-tools was updated recently and it updated the dat.gui dependency which should hopefully fix this problem.

chazapp avatar Feb 03 '21 12:02 chazapp

temporary solution

https://classic.yarnpkg.com/en/docs/selective-version-resolutions/:

Add this to your package.json file:

  "resolutions": {
    "matter-tools": "0.14.0",
  }

wojciech-skowronek avatar Apr 23 '21 14:04 wojciech-skowronek