Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

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

unpexpected : due to type definition in TS #211

Open
deepakaggarwal7 opened this issue Oct 6, 2023 · 1 comment
Open

unpexpected : due to type definition in TS #211

deepakaggarwal7 opened this issue Oct 6, 2023 · 1 comment

Comments

@deepakaggarwal7
Copy link

deepakaggarwal7 commented Oct 6, 2023

TS file method with datatype in function doesn't work.

myFunction inside somefile.ts, which is rewired
Doesn't work

function myFunction(a: number, b: number) {
  return a + b;
}

Error thrown: SyntaxError: Unexpected token ':'

Works

function myFunction(a, b) {
  return a + b;
}

@nktnet1
Copy link

nktnet1 commented Oct 9, 2023

There are some workarounds in #185

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants