Worked just fine yesterday, but today I suddenly got this error when running 'grunt server':
Running "bowerInstall:app" (bowerInstall) task
Warning: Cannot read property 'main' of undefined Use --force to continue.
Aborted due to warnings.
I even did a hard reset to the previous commit, but I still get the same error. What could be causing this?
Git repo: https://github.com/oyvindhellenes/Corsane
To solve the "Cannot read property of undefined" error, make sure to insert the JS script tag at the bottom of the body. The JS script tag should be placed after the HTML elements have been declared. Copied!
The enum error - cannot read property of undefined occurs for 2 main reasons: Using const enums that get removed during compilation. Having circular imports (importing members between the same files).
Undefined means that a variable has been declared but has not been assigned a value. In JavaScript, properties and functions can only belong to objects. Since undefined is not an object type, calling a function or a property on such a variable causes the TypeError: Cannot read property of undefined.
In JavaScript, properties and functions can only belong to objects. Since undefined is not an object type, calling a function or a property on such a variable causes the TypeError: Cannot read property of undefined.
Okay this is awkward. A simple 'bower install' did the trick.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With