0

I have this Typescript code for my lit component:

  render () {
    const graph : GVGraph = this.graph
    const svgEle = graph.asSVG()
    return html`
       ${svgEle}
    `
  }

Everything works well in my IDE VS Code. Typescript transpiler doesn't complain. Vite does also do its magic. But at runtime Safari shows this error:

TypeError: graph.asSVG is not a function. (In 'graph.asSVG()', 'graph.asSVG' is undefined)

But the method is even in the sources of the browser... see here (see class/method): enter image description here

So, how could that be? Why would the code fail at runtime? Any ideas? Where do I need to look?

Thank you!

Wizard of Kneup
  • 1,863
  • 1
  • 18
  • 35

0 Answers0