-
Notifications
You must be signed in to change notification settings - Fork 876
Importing barrels with '../shared' fails #1896
Comments
do you have the index.ts file that exports the component and that added to the system config? /cc @filipesilva |
It also seems to me that it's not being added to system-config. Basically, System does not know that |
I create a sample project from scratch to reproduce the problem: https://github.com/francisoud/angular.io.issue.1896 You were right the problem is in system-config.ts there are 2 lines that are missing and should have been added during
I think it's a bug in angular-cli |
@francisoud can you open this issue in https://github.com/angular/angular-cli instead then? It does sound like a bug in the CLI. |
Closing this one :) |
Importing barrels as explain in https://angular.io/styleguide#!#04-10 doesn't work with @angular2@2.0.0.rc3 or [email protected] (I don't know which one is faulty ;) )
I have a
contract-list/contract-list.component.spec.ts
Karma fails:
...
Workaround:
import { ContractService } from '../shared';
with
import { ContractService } from '../shared/index';
I think I got the same issue inside a component (not a test)...
The text was updated successfully, but these errors were encountered: