Closed RichLinnell closed 8 years ago
Since SystemJS is loaded as a global dependency in the global scope, you can check by your self if the whole object is available and hence if the System.import() function is accessible, by inspecting both from the Dev Tools. Just open your app and type System
and System.import
(take advantage of the auto-complete features for this) to see if you get an output like this:
If not, please make sure that your node_modules folder contains all the required SystemJS files and the also check your <script>
blocks are in the right order.
Do you get the same error when downloading and building the code from this repo?
Hi Pablo,
Sorted it out. I had mistakenly typed
<script>
System.Import('built/hello-angular');
</script>
instead of
<script>
System.import('built/hello-angular');
</script>
Sorry for wasting your time. Your pointer about using the immediate tools in the browser pointed me in the right direction.
Thanks for letting me know. It is always a pleasure to help.
Hope you're enjoying the book. :)
Hi,
I've followed the book almost to the letter, deviating only slightly to skirt around a small coding issue in index.html that had no open script tag and now when I try to run the Hello Angular I am getting the following error
(index):15 Uncaught TypeError: System.Import is not a function(anonymous function) @ (index):15
The system.js script is definitely being loaded, chrome is not giving any errors (if I deliberately misname the system.js src it does give an error).
Any pointers greatly appreciated.