api.modifyClass("component:modal/poll-ui-builder", {
pluginId: 'poll-defaults',
didInsertElement() {
this._super(...arguments); // super.didInsertElement(...arguments); 가 작동하지 않음 (?)
if (settings.Public) {this.set('publicPoll', true)}
if (settings.Advanced) {this.set('showAdvanced', true)}
},
});
이렇게 하면 작동합니다.
하지만 didInsertElement에 대해 혼란스럽습니다. poll-ui-builder는 이제 glimmer 컴포넌트입니다. ember 업그레이드 가이드에 따르면 didInsertElement는 존재해서는 안 됩니다.
코어에서 일부 사용 사례를 볼 수 있습니다. Discourse에 어떤 특수성이 있는 걸까요?
또한, 위 코드 컨텍스트에서 super.didInsertElement가 존재하지 않는 이유도 확실하지 않습니다.