I have two modules gridusers module and users module.The grid module will list the all users in data table , when I click the action item edit it will open a popup to edit the users. With the edit user, I'm trying to create a component in user module. When I try to use that edit user component in gridusers module, I'm getting an error:
template parse error and Uncaught (in promise): Error: Template parse errors: 'app-edit-user' is not a known element:
- If 'app-edit-user' is an Angular component, then verify that it is part of this module.
- If 'app-edit-user' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
Any help on this?
gridmodule
-- gridmodule.ts
-- gridcomponent.ts
-- gridcomponent.html
-- gridcomponent.scss
usermodule
-- usermodule.ts
-- usercomponent.ts
-- usercomponent.html
-- editusercomponent.ts
-- editusercomponent.html
-- usercomponent.scss
-- editusercomponent.scss
editusercomponent.ts
import { Component } from '@angular/core';
@Component({
selector: 'app-edit-user',
templateUrl: './editusercomponent.html',
styleUrls: ['./editusercomponent.scss']
})
export class editusercomponent{
title = 'edit user';
}
gridmodule.ts
@NgModule({
declarations: [
editusercomponent
],
imports: [
.-----
],
})