Closed Bengejd closed 5 years ago
Thanks for the notice. I can't repro the error. Can you strip the file of anything not necessary to reproduce the error and post it here? Thanks.
Hmmm. After doing some more testing, and stripping out everything from the file, it turns out it's linked directly to when you are setting a public variable to be undefined, while also importing rxjs in the manner I mentioned above. When you comment out the rxjs import line, the file proceeds as normal, and the same occurs if you comment out the undefined variable instead of the rxjs import.
Here is a simplified file:
import 'rxjs/add/operator/map'; // Comment out this, and it works.
import { Injectable } from '@angular/core';
@Injectable()
export class TestService {
user: any = undefined; // Or comment out this, and it works.
constructor() {}
}
So running it as is, will throw the error, but commenting out either the variable or the import, it will work as expected.
Thanks. Will get a fix for it soon.
Update to 1.4.1
Thanks again.
Thanks for the quick turnaround!
This seems to occur when importing rxjs via:
import 'rxjs/add/operator/map';