ondras / rot.js

ROguelike Toolkit in JavaScript. Cool dungeon-related stuff, interactive manual, documentation, tests!
https://ondras.github.io/rot.js/hp/
BSD 3-Clause "New" or "Revised" License
2.33k stars 254 forks source link

Problem with npm package #117

Closed bkjohnson closed 7 years ago

bkjohnson commented 7 years ago

I ended up going with bower like you said in the readme, but I first tried with npm since I saw it published there so I thought I'd mention this. When I installed rot using npm loading the file at node_modules/rot-js/lib/rot.js throws an error:

image

Specifically it is talking about this line

Just thought I'd bring this to your attention. So far I haven't had problems with the bower version.

ondras commented 7 years ago

The npm package is meant for NodeJS only. Browser users are supposed to simply include https://github.com/ondras/rot.js/blob/master/rot.min.js using a <script> node.

bkjohnson commented 7 years ago

Got it, thanks!