Physijs
Physijs copied to clipboard
Add support for AMD, commonjs and browser-only
Added a header to play nicely with commonjs, amd and classic window exports
NAVER - http://www.naver.com/
[email protected] 님께 보내신 메일 <[Physijs] Add support for AMD, commonjs and browser-only (#217)> 이 다음과 같은 이유로 전송 실패했습니다.
받는 사람이 회원님의 메일을 수신차단 하였습니다.
I believe full support should also take away the necessity of these statements:
// set worker and ammo
Physijs.scripts.worker = 'static/plugins/physijs/physijs_worker.js';
Physijs.scripts.ammo = 'ammo.js';
Otherwise this also fixes #213
+1
Here's a browserify version, but general npm support would be awesome.
So I forked the browserify version a few years ago and could never get it working with require
s, without the scripts
configuration, and without having to copy files around.
Randomly decided to pick it up this weekend and managed to create an auto-configured version for both webpack and browserify that's just a single require
, no scripts
configuration, no copying files, etc. See https://github.com/agilgur5/physijs-webpack
It only uses CommonJS right now, but given it's for Webpack etc, there shouldn't be a need to support anything else. Not quite the same what this PR does, but for a very related purpose.