Meteor_angularjs
Meteor_angularjs copied to clipboard
Error message with new Meteor 0.4.2
mrt create test && cd test && mrt add angularjs && mrt run
Go to browser, open console and see:
ReferenceError: Can't find variable: __meteor_runtime_config__
url_common.js:38
Adding these lines in server.js
, right after code = code.replace("<html>",'<html ng-app="meteorapp">');
solves the problem :
if (typeof __meteor_runtime_config__ !== 'undefined') {
code = code.replace(
"// ##RUNTIME_CONFIG##",
"__meteor_runtime_config__ = " +
JSON.stringify(__meteor_runtime_config__) + ";");
}
But I don't know if it's a good solution.
It is a good fix @TiuSh . The error will be fixed when I release the new version of the angularjs for Meteor. It will come soon .
I see that error for meteor 0.5.2
@aprnsk Are you using the latest version?
yes