let를 시도해 보았지만 결과는 동일했습니다. 보통 fetch()나 ajax()를 사용할 때는 const를 사용하거든요.
에ラー가 static template = 줄에서 발생한다고 생각합니다. 이 줄을 사용하면 다음과 같은 에러가 나요:
[THEME 10283 'Pokemon Theme'] Error: connector component has no associated template. Ensure the template is colocated or authored with gjs.
at h (plugin-connectors.js:35:11)
at eY.renderInOutlet (plugin-api.gjs:1116:5)
at todo.gjs:43:7
at eH (plugin-api.gjs:3363:10)
at Object.initialize (api.js:21:14)
at i.initialize (app.js:265:28)
at index.js:379:19
at e.each (index.js:183:7)
at e.walk (index.js:112:10)
at e.each (index.js:59:20)
at e.topsort (index.js:65:10)
at iL._runInitializer (index.js:392:11)
at iL.runInstanceInitializers (index.js:377:10)
at l._bootSync (instance.js:116:22)
at iL.didBecomeReady (index.js:784:18)
at invoke (index.js:262:14)
at m.flush (index.js:180:11)
at g.flush (index.js:334:19)
at z._end (index.js:762:32)
at _boundAutorunEnd (index.js:499:12)
그냥 <template>을 직접 사용하면 에러가 발생하지 않습니다. 여기서는 static template을 사용하는 것이 유효하지 않다고 생각하므로, 템플릿 태그를 직접 사용하는 것이 작동합니다.