Cannot read property 'prepareStyles' of undefined

前端 未结 2 1673
北海茫月
北海茫月 2021-01-12 11:28

I am trying to open a Dialog box by a button click. When I am clicking the button the Dialog first of all is not opened and I am getting Error :

2条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-12 11:46

    I don't have enough rep to comment on Mayank's answer but they are correct. To further elaborate on Maynak's answer, you only need to add to the main app container. If you do that, you should never have to worry about adding it anywhere else in your app.

    Note the parent component on the left and the child component in this image:

提交回复
热议问题