添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
相关文章推荐
安静的手链  ·  html2canvas 和 ...·  3 周前    · 
慈祥的饺子  ·  解决“Could not obtain ...·  2 月前    · 
潇洒的硬币  ·  JetsonNano指南 | spaceman·  4 月前    · 

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement . We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

While trying to convert an existing large vue (nuxt) project to typescript I'm having an error error TS1005: ')' expected. in multiline expressions in vue templates

Example:

<template>
    @click="
      myFunc()
      myVar = 42
</template>

Not sure if this is an expected behavior, but here's a minimal reproduction link:

https://github.com/halimb/nuxt-edge-ts

Any idea how to solve this?

Thanks

The handler value can be one of the following:

  • Inline handlers: Inline JavaScript to be executed when the event is triggered (similar to the native onclick attribute).
  • Method handlers: A property name or path that points to a method defined on the component.
  • The value is simply invalid, you should wrap it into a function.