-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add Glint check for inferred type of
and
and or
helpers
- Loading branch information
Sergey Astapov
committed
Sep 2, 2023
1 parent
7b251ea
commit 9766373
Showing
3 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
4 changes: 4 additions & 0 deletions
4
packages/modern-test-app/app/components/and-or-type-checking.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<div> | ||
{{log @andArg}} | ||
{{log @orArg}} | ||
</div> |
19 changes: 19 additions & 0 deletions
19
packages/modern-test-app/app/components/and-or-type-checking.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import templateOnly from '@ember/component/template-only'; | ||
|
||
interface Signature { | ||
Element: HTMLDivElement; | ||
Args: { | ||
andArg: object | boolean; | ||
orArg: object | boolean; | ||
}; | ||
} | ||
|
||
const AndOrTypeChecking = templateOnly<Signature>(); | ||
|
||
export default AndOrTypeChecking; | ||
|
||
declare module '@glint/environment-ember-loose/registry' { | ||
export default interface Registry { | ||
AndOrTypeChecking: typeof AndOrTypeChecking; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters