Urigo / Ionic2CLI-Meteor-WhatsApp

WhatsApp Clone tutorial with Ionic 2.0 CLI and Meteor Server
https://www.angular-meteor.com/tutorials/whatsapp2/ionic/setup
163 stars 184 forks source link

reference error Metor is not defined #181

Closed mdy405 closed 6 years ago

mdy405 commented 6 years ago

I m following this Tutorial from scratch but after running npm run meteor-client:bundle, everytime i m trying yo run the app (ionic serve ), i got this on my Browser:

ReferenceError: Meteor is not defined [En savoir plus] meteor-client.js:32516

@http://localhost:8100/build/vendor.js:136343:3 @http://localhost:8100/build/vendor.js:103827:29 webpack_require@http://localhost:8100/build/vendor.js:55:12 [482]@http://localhost:8100/build/main.js:286:1 webpack_require@http://localhost:8100/build/vendor.js:55:12 webpackJsonpCallback@http://localhost:8100/build/vendor.js:26:23 @http://localhost:8100/build/main.js:1:1

petr-istratov commented 6 years ago

Had same issue after updating meteor to 1.6.1 Tried to downgrade back to 1.6-rc.7 - and getting now Errors prevented bundling:
While loading plugin basicFileTypes from package meteor: packages/basicFileTypes_plugin.js:39:9: Package._define is not a function at packages/basicFileTypes_plugin.js:39:9 at packages/basicFileTypes_plugin.js:41:3

while doing bundling

palamethos commented 6 years ago

same issue as @mazzafuccka

poparotsy commented 6 years ago

179

mwildlumira commented 6 years ago

That didn't work for me. I'm seeing exactly the same issue after recreating api with --release 1.6 and following the rest of the bullets above.

Errors prevented bundling:
While loading plugin basicFileTypes from package meteor: packages/basicFileTypes_plugin.js:39:9: Package._define is not a function at packages/basicFileTypes_plugin.js:39:9 at packages/basicFileTypes_plugin.js:41:3

/usr/local/lib/node_modules/meteor-client-bundler/node_modules/execa/index.js:277 throw (result.error || new Error(result.stderr === '' ? result.stdout : result.stderr)); ^

Error: null at Function.module.exports.sync (/usr/local/lib/node_modules/meteor-client-bundler/node_modules/execa/index.js:277:26) at Object.bundle (/usr/local/lib/node_modules/meteor-client-bundler/lib/bundler.js:97:9) at Command. (/usr/local/lib/node_modules/meteor-client-bundler/cli:47:13) at Command.listener (/usr/local/lib/node_modules/meteor-client-bundler/node_modules/commander/index.js:315:8) at emitTwo (events.js:126:13) at Command.emit (events.js:214:7) at Command.parseArgs (/usr/local/lib/node_modules/meteor-client-bundler/node_modules/commander/index.js:651:12) at Command.parse (/usr/local/lib/node_modules/meteor-client-bundler/node_modules/commander/index.js:474:21) at Object. (/usr/local/lib/node_modules/meteor-client-bundler/cli:55:9) at Module._compile (module.js:643:30)

mwildlumira commented 6 years ago

I couldn't find a solution for the Package._define issue but did find a fix for meteor-client bundler to make it work with v1.6.1 of Meteor. This does solve the original issue of 'ReferenceError: Meteor is not defined'.

The fix hasn't been merged yet so it will need manually applying. See here for a fix:

https://github.com/Urigo/meteor-client-bundler/issues/54

Urigo commented 6 years ago

just released meteor-client-bundler@0.4.0, let me know if that solves this problem