Skip to content
This repository has been archived by the owner on Dec 19, 2018. It is now read-only.

DefaultTagHelperFactService does not handle opt-out TagHelpers correctly. #1186

Closed
NTaylorMullen opened this issue Apr 6, 2017 · 1 comment
Assignees

Comments

@NTaylorMullen
Copy link
Member

If we have a the following tag: <!a href="...">Hello</!a>. You can't query DefaultTagHelperFactService for !a; you need to query it for just the a. If you happen to have a TagHelper that can match !a (a catch-all) then it will apply.

@NTaylorMullen NTaylorMullen added this to the 2.0.0-preview1 milestone Apr 6, 2017
@NTaylorMullen NTaylorMullen self-assigned this Apr 6, 2017
NTaylorMullen added a commit that referenced this issue Apr 6, 2017
- Prior to this change the `TagHelper` parsing would strip the opt-out character (`!`) from tag names that got passed to the TagHelper matching services. At design time this proved to be a problem because they have their own understanding of the HTML document and only pass us full tag names (names that include `!`). This changes the matching conventions to immediately return false if a tag name is seen to contain the `TagHelper` opt-out.
- Added two `DefaultTagHelperFactService` tests to verify that tag names with opt-out prefixes are denied `TagHelperDescriptor`s.

#1186
NTaylorMullen added a commit that referenced this issue Apr 6, 2017
- Prior to this change the `TagHelper` parsing would strip the opt-out character (`!`) from tag names that got passed to the TagHelper matching services. At design time this proved to be a problem because they have their own understanding of the HTML document and only pass us full tag names (names that include `!`). This changes the matching conventions to immediately return false if a tag name is seen to contain the `TagHelper` opt-out.
- Added two `DefaultTagHelperFactService` tests to verify that tag names with opt-out prefixes are denied `TagHelperDescriptor`s.

#1186
NTaylorMullen added a commit that referenced this issue Apr 6, 2017
- Prior to this change the `TagHelper` parsing would strip the opt-out character (`!`) from tag names that got passed to the TagHelper matching services. At design time this proved to be a problem because they have their own understanding of the HTML document and only pass us full tag names (names that include `!`). This changes the matching conventions to immediately return false if a tag name is seen to contain the `TagHelper` opt-out.
- Added two `DefaultTagHelperFactService` tests to verify that tag names with opt-out prefixes are denied `TagHelperDescriptor`s.

#1186
NTaylorMullen added a commit that referenced this issue Apr 6, 2017
- Prior to this change the `TagHelper` parsing would strip the opt-out character (`!`) from tag names that got passed to the TagHelper matching services. At design time this proved to be a problem because they have their own understanding of the HTML document and only pass us full tag names (names that include `!`). This changes the matching conventions to immediately return false if a tag name is seen to contain the `TagHelper` opt-out.
- Added two `DefaultTagHelperFactService` tests to verify that tag names with opt-out prefixes are denied `TagHelperDescriptor`s.

#1186
@NTaylorMullen
Copy link
Member Author

0005cb9

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant