Open paulalbertdev opened 5 years ago
Just discovered that angular execution is broken when this error occurs , some other things that should happen after won't. So, I think this bug is blocking...
I was a bit desperate and started to read every issues reported here and found this one (with a totally different problem) https://github.com/isaacplmann/ngx-contextmenu/issues/150 BUT they suggested to add #basicMenu to the context-menu tag, ANNNNND BINGO ! It Works ! You should maybe consider to update the template in your documentation ( https://github.com/isaacplmann/ngx-contextmenu )
It works for me after I change this line in component.xxx.ts
@ViewChild(ContextMenuComponent, { static: false }) public basicMenu: ContextMenuComponent;
to
@ViewChild(ContextMenuComponent, { static: true }) public basicMenu: ContextMenuComponent;
Describe the bug Context menu is working, but I've still got an error in the dev console :
To Reproduce Made a stackblitz (take a look at the console) based on your examples https://stackblitz.com/edit/ngx-contextmenu-example-p3cmlw?file=src%2Fapp%2Fapp.component.ts
Expected behavior This should not throw an error