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

False positive no-undef for template-imports and contextual components #1747

Closed
simonihmig opened this issue Jan 18, 2023 · 2 comments · Fixed by #1920 or #1942
Closed

False positive no-undef for template-imports and contextual components #1747

simonihmig opened this issue Jan 18, 2023 · 2 comments · Fixed by #1920 or #1942
Labels

Comments

@simonihmig
Copy link

This is failing linting with form and field "locals" (they are not local to the outer template scope, so not supposed to be provided by JS scope, which ESLint thinks here) falsely violating no-undef:

<template>
  <HeadlessForm @data={{data}} as |form|>
    <form.field @name="firstName" as |field|>
      <field.label>First Name</field.label>
      <field.input data-test-first-name />
    </form.field>
    <form.field @name="lastName" as |field|>
      <field.label>Last Name</field.label>
      <field.input data-test-last-name />
    </form.field>
  </HeadlessForm>
</template>

I think I have identified the root cause in @glimmer/syntax, keeping this for tracking. /cc @NullVoxPopuli

@simonihmig
Copy link
Author

My attempt to fix this upstream: glimmerjs/glimmer-vm#1406

@bmish
Copy link
Member

bmish commented Aug 22, 2023

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