Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

planck-js

piqnt4kMITdeprecated1.3.0TypeScript support: included

Please use 'planck' package instead of 'planck-js'

2D JavaScript/TypeScript physics engine for cross-platform HTML5 game development

box2d, html5, javascript, typescript, game, physics, engine, 2d, mobile

readme

Planck.js

Planck.js is JavaScript/TypeScript rewrite of Box2D physics engine for cross-platform HTML5 game development.

Motivations

  • Taking advantage of Box2D's efforts and achievements
  • Developing readable and editable code in JavaScript/TypeScript
  • Providing idiomatic JavaScript/TypeScript API
  • Optimizing the library for web and mobile platforms

Documentation

Examples

Discord

Made with Planck.js

Report Issues

To speed up resolving issues, please provide testbed code to reproduce the issue.

changelog

planck

1.3.0

Minor Changes

  • bb9bb87: Testbed rendering rewrite
  • 56193e7: Add DataDriver (experimental for demo use-case)

Patch Changes

  • ce1c486: No pointer interaction when mouseForce===0

1.2.0

Minor Changes

  • f0127f4: Add world.queueUpdate() to queue and defer updates after current simulation step

Patch Changes

  • 97bb79e: Improve world.queueUpdate

1.1.6

Patch Changes

  • f31114b: Add static Vec2.normalize
  • bee0e16: Change clampVec2 arg to Vec2Value

1.1.5

Patch Changes

  • fbd0021: Un-hidden style field type