I'm working on angular library and creating each component as independent modules. I have created own ErrorStateMatcher
& error config and placed it in different folder (./errors
) so I can reuse them in other components. I'm getting following errors when I put these files in different folder and import in input.component.ts
.
Note: no errors when include these files in input folder.
✖ Compiling with Angular sources in Ivy partial compilation mode.
error TS6059: File '[path to app]/projects/mint/errors/error-option.ngtypecheck.ts' is not under 'rootDir' '[path to app]/projects/mint/input'. 'rootDir' is expected to contain all source files
input.component.ts
import { MintErrorMatcher } from '../errors/error-option';
import { _MintInputBase } from '../errors/error-state';
@Component({
selector: 'mint-input',
...
providers: [
{
provide: ErrorStateMatcher,
useClass: MintErrorMatcher,
},
]
})
export class MintInputComponent extends _MintInputBase { ... }