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

Multi-parameter generics breaks all syntax highlighting in the rest of the file #807

Closed
Pajn opened this issue Feb 16, 2020 · 0 comments
Closed

Comments

@Pajn
Copy link

Pajn commented Feb 16, 2020

TS and JS Grammar Extension version: 0.0.53 / latest

Code

const { loading, error, data } = useQuery<{
  tasks: Array<Pick<Task, 'id' | 'title'>>
}>(taskListQuery)

if (loading) return <p>Loading...</p>
if (error)
  return (
    <>
      <p>Error :(</p>
      <p>{`${error}`}</p>
    </>
  )

This does not break the syntax highlighting:

const { loading, error, data } = useQuery<{
  tasks: Array<Pick<Task>>
}>(taskListQuery)

if (loading) return <p>Loading...</p>
if (error)
  return (
    <>
      <p>Error :(</p>
      <p>{`${error}`}</p>
    </>
  )
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

1 participant