{"action":"opened","issue":{"url":"https://api.github.com/repos/MrRio/jsPDF/issues/474","labels_url":"https://api.github.com/repos/MrRio/jsPDF/issues/474/labels{/name}","comments_url":"https://api.github.com/repos/MrRio/jsPDF/issues/474/comments","events_url":"https://api.github.com/repos/MrRio/jsPDF/issues/474/events","html_url":"https://github.com/MrRio/jsPDF/issues/474","id":66661418,"number":474,"title":"TypeError: Cannot read property 'document' of undefined","user":{"login":"chip","id":31725,"avatar_url":"https://avatars.githubusercontent.com/u/31725?v=3","gravatar_id":"","url":"https://api.github.com/users/chip","html_url":"https://github.com/chip","followers_url":"https://api.github.com/users/chip/followers","following_url":"https://api.github.com/users/chip/following{/other_user}","gists_url":"https://api.github.com/users/chip/gists{/gist_id}","starred_url":"https://api.github.com/users/chip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chip/subscriptions","organizations_url":"https://api.github.com/users/chip/orgs","repos_url":"https://api.github.com/users/chip/repos","events_url":"https://api.github.com/users/chip/events{/privacy}","received_events_url":"https://api.github.com/users/chip/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-04-06T17:38:29Z","updated_at":"2015-04-06T17:38:29Z","closed_at":null,"body":"I'm having trouble getting this to work in a Meteor app.  Here's what I did:\r\n\r\n**Cloned the repo recursively:**\r\n```\r\ngit clone --recursive git://github.com/MrRio/jsPDF.git\r\n```\r\n\r\n**Copied the minified file from the dist folder to my meteor project**\r\n```\r\ncp jsPDF/dist/jspdf.min.js invoicethat.com/lib/compatibility/\r\n```\r\n\r\n**Started meteor**\r\n```\r\nmeteor                                                                 [18/2455]\r\n[[[[[ ~/code/invoicethat.com ]]]]]            \r\n\r\n=> Started proxy.                             \r\n=> Meteor 1.1.0.1 is available. Update this project with 'meteor update'.\r\n=> Started MongoDB.                           \r\nW20150406-12:30:37.174(-5)? (STDERR)          \r\nW20150406-12:30:37.175(-5)? (STDERR) /Users/chip/.meteor/packages/meteor-tool/.1.0.45.1xrpsay++os.osx.x86_64+web.browse\r\nr+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:245\r\nW20150406-12:30:37.175(-5)? (STDERR)                                            throw(ex);\r\nW20150406-12:30:37.175(-5)? (STDERR)                                                  ^\r\nW20150406-12:30:37.175(-5)? (STDERR) TypeError: Cannot read property 'document' of undefined\r\nW20150406-12:30:37.176(-5)? (STDERR)     at r (app/lib/compatibility/jspdf.min.js:170:3428)\r\nW20150406-12:30:37.176(-5)? (STDERR)     at app/lib/compatibility/jspdf.min.js:170:5695\r\nW20150406-12:30:37.176(-5)? (STDERR)     at app/lib/compatibility/jspdf.min.js:171:11352\r\nW20150406-12:30:37.176(-5)? (STDERR)     at app/lib/compatibility/jspdf.min.js:173:3\r\nW20150406-12:30:37.176(-5)? (STDERR)     at /Users/chip/code/invoicethat.com/.meteor/local/build/programs/server/boot.j\r\ns:222:10\r\nW20150406-12:30:37.176(-5)? (STDERR)     at Array.forEach (native)\r\nW20150406-12:30:37.176(-5)? (STDERR)     at Function._.each._.forEach (/Users/chip/.meteor/packages/meteor-tool/.1.0.45\r\n.1xrpsay++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/underscore/undersco\r\nre.js:79:11)\r\nW20150406-12:30:37.176(-5)? (STDERR)     at /Users/chip/code/invoicethat.com/.meteor/local/build/programs/server/boot.j\r\ns:117:5\r\n=> Exited with code: 8\r\n```\r\n\r\nSeveral lines down in the stack trace you'll notice the error, **\"TypeError: Cannot read property 'document' of undefined\"**.\r\n\r\nI have also tried copying the `jspdf.debug.js` file, but I get the same error.\r\n\r\nAdditionally, I've tried using the resulting files after running `./build.sh` from within the repo.\r\n\r\nAny suggestions on how to resolve this issue or even build the project would be very helpful. Thank you."}}