Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
3880 มุมมอง
class FavoriteMenu extends DropdownMenu {
 constructor() {
super(...arguments);
this.model = useModel('searchModel');              this.state.deletedFavorite = false;
}
}

I want to extend the constructor of `FavoriteMenu` .. like adding console.log after super(...arguments)

So the result would be redefining the main constructor in  custom file but the result is obtained in the main file

I've tried `FavoriteMenu.include` and `FavoriteMenu.prototype.cconstructor`but they didn't work


any hint?

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
มี.ค. 24
7174
0
ม.ค. 21
8538
2
มิ.ย. 22
11538
0
ต.ค. 22
571
1
ส.ค. 21
4543