question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Attribute [for] to label doesn't exist

See original GitHub issue
<label [for]="controlPath">{{controlPath | uppercase}}</label>
controlPath: string;

Error shown: EXCEPTION: Can’t bind to ‘for’ since it isn’t a known property of the ‘<label>’ element and there are no matching directives with a corresponding property

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

6reactions
pkozlowski-opensourcecommented, Aug 24, 2015

Right, there is no for property on label, there is only an _attribute. You have to use <label [attr.for]="controlPath"> to bind to attributes.

0reactions
angular-automatic-lock-bot[bot]commented, Sep 7, 2019

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How can I use the FOR attribute of a LABEL tag without the ID ...
If there is an element on the page with an id matching the label's for attribute, revert to default functionality and focus that...
Read more >
Labeling Controls | Web Accessibility Initiative (WAI) - W3C
Labels need to describe the purpose of the form control. This section of the tutorial describes how to provide labels that are properly...
Read more >
aria-label - Accessibility - MDN Web Docs
The aria-label attribute defines a string value that labels an interactive element.
Read more >
The resource key X used by the label of attribute Y does not ...
Hello Mehdi,. In the UI Hints tab of you Entity Object the Label property is probably pointing to a value specified in ModelBundle.properties ......
Read more >
UpdateItem - Amazon DynamoDB - AWS Documentation
... item's attributes, or adds a new item to the table if it does not already exist. ... item (insert a new attribute...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found