New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(SystemJS) Block-scoped declarations #425

pra7eek opened this Issue Apr 3, 2017 · 3 comments


None yet
4 participants

pra7eek commented Apr 3, 2017


I'm getting following error while running the quickstart project in google chrome:

Error: (SystemJS) Block-scoped declarations (let, const, function, class) not yet supported outside strict mode(…)

This error is occurring due to the following line
System.import('main.js').catch(function(err){ console.error(err); });

I'm running ubuntu 14.04. The weird part is that the project is running pretty well in mozilla but not in chrome. Please help.


This comment has been minimized.

seasoncc commented May 8, 2017

i also have the exact problem happened on lower chrome version just like 44 or 45, but fine on the recent Chrome version. PS, angular 4 used. Please help.


This comment has been minimized.

hinok commented Sep 27, 2017

This error should be fixed by 418dc2e#diff-752ce8d1e20589d7d48a4df20913ad12

Please check that you are using latest version of systemjs-angular-loader.js.

Add 'use strict'; at the beginning of systemjs-angular-loader.js

So this file should look like:

'use strict'; // This line is missing and fixes problem

var templateUrlRegex = /templateUrl\s*:(\s*['"`](.*?)['"`]\s*)/gm;
var stylesRegex = /styleUrls *:(\s*\[[^\]]*?\])/g;
var stringRegex = /(['`"])((?:[^\\]\\\1|.)*?)\1/g;

// rest of the code

This comment has been minimized.


Foxandxss commented Oct 31, 2017

This repository is now deprecated. The Angular Quickstart project was a nice starting point for creating Angular applications. Now we recommend using the Angular CLI to create new Angular projects.

Starting from 1 November 2017, all the Angular documentation, at, is based on the Angular CLI.

Let's get started

@Foxandxss Foxandxss closed this Oct 31, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment