I am having issues setting up the sidebar on an already existing asp.net mvc core application. I believe I have imported all the necessary files to have the side bar running: app.menu.component.ts, app.menu.component.html, app.sidebar.component.ts, app.sidebar.component.html, app.sidebartabcontent.component.ts. Think I have setup all the dependencies correctly in app.component and app.module. But am getting this error:
Property 'eventEmitter' does not exist on type 'MenuItem'.
Am I missing another dependency for app.menu.component.ts ?
Compilation issue while setting up sidebar
Forum rules
Please note that response time for technical support is within 3-5 business days.
Please note that response time for technical support is within 3-5 business days.
Hi,
We will update all layouts to the latest versions of angular (4.2.x) and primeng (4.1.0) soon.
But before that, you can use it like this.
Regards
We will update all layouts to the latest versions of angular (4.2.x) and primeng (4.1.0) soon.
Code: Select all
itemClick(event: Event, item: MenuItem, index: number) {
//avoid processing disabled items
if(item.disabled) {
event.preventDefault();
return true;
}
//activate current item and deactivate active sibling if any
this.activeIndex = (this.activeIndex === index) ? null : index;
//execute command
if(item.command) {
item.command({
originalEvent: event,
item: item
});
}
//prevent hash change
if(item.items || (!item.url && !item.routerLink)) {
event.preventDefault();
}
//hide menu
if(!item.items && (this.app.overlay || !this.app.isDesktop())) {
this.app.sidebarActive = false;
}
}
Regards
-
- Information
-
Who is online
Users browsing this forum: No registered users and 3 guests