This repository was archived by the owner on Dec 19, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 223
Allow tag helpers to target elements by attribute #311
Comments
NTaylorMullen
added a commit
that referenced
this issue
Mar 2, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 2, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 3, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 3, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 5, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 5, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 11, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 11, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 14, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 14, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
NTaylorMullen
added a commit
to aspnet/Mvc
that referenced
this issue
Mar 18, 2015
NTaylorMullen
added a commit
that referenced
this issue
Mar 18, 2015
- Transitioned HtmlElementNameAttribute into a more generic TargetElementAttribute. Targeting an HTML element can be done by attribute, tag or both. - Updated TagHelperDescriptor to track required attributes. - Updated TagHelperProvider to ask for provided attributes when resolving TagHelperDescriptors, this is used to apply RequiredAttributes. - Updated TagHelperParseTreeRewriter to properly track HTML elements that coincide with a TagHelper scope based on the presence of RequiredAttributes. #311
NTaylorMullen
added a commit
that referenced
this issue
Mar 18, 2015
- Added tests to validate TargetElementAttribute, TagHelperDescriptorFactory, CSharpTagHelperCodeRenderer and TagHelperParseTreeRewriterTests. - Renamed HtmlElementNameAttributeTest to TargetElementAttributeTest. #311
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Currently, tag helpers target elements by element name. They should also be able to target elements via attribute names. This would allow tag helpers to easily target existing elements in a more aspect oriented fashion. It also has the benefit of potentially reducing overhead for said tag helpers, because they're only attached to elements that explicitly opt-in via the attribute.
Some of the MVC tag helpers we've already written would utilize this feature, e.g. validation summary.
A tag helper should be able to target elements by element name(s), attribute name(s), or both. They should be able to specify their targets in groups to allow for both AND and OR combinations.
Attribute names should support partial wild-cards, e.g.
asp-param-*
.Examples
The text was updated successfully, but these errors were encountered: