sebaferreras / Ionic3-MultiLevelSideMenu

Ionic 3 demo of a two-level side menu.
MIT License
136 stars 55 forks source link

What if I want subItems of subItems and so on..?? #16

Open Nayan014 opened 7 years ago

Nayan014 commented 7 years ago

I want 4 level side menu

I tried to push option as mention bellow but it is not working. also played with side-menu-content.component.html but didn't get what to do, Can you please guide where else I have to make changes.

Thank you for your great contribution.

this.options.push({ displayName: 'Nayan', subItems: [ { iconName: 'basket', displayName: 'Sub Option 1', subItems: [ { iconName: 'basket', displayName: 'Sub Option 1', component: 'HomePage' }, { iconName: 'bookmark', displayName: 'Sub Option 2', component: 'HomePage' } ] }, { iconName: 'bookmark', displayName: 'Sub Option 2', component: 'HomePage' } ] });

sebaferreras commented 7 years ago

I'm afraid it won't be possible with the current implementation of the component. The entire logic of the component is based on only two levels of items/subitems, so a major refactor of the entire code would be needed in order to support more levels of items/subitems.

I'll add support for multiple levels in the future but since it's a major change and requires a lot of time, I won't be able to do it in the short time, I'm very sorry :(

I'll keep this issue open so we can add ideas/suggestions/comments here.