aspnetcore/test/Microsoft.AspNetCore.Blazor.../TestFiles/DesignTimeCodeGenerationTest
Ryan Nowak c97cb8c18b Add support for Razor templates
Adds support for Razor templates and RenderFragment<T>.

Razor templates are a little-known Razor feature that looks like:
```
@<tag>....<tag>
```

It's so little known that it's not even covered in our docs, but it's
been around for many many years. This features hasn't been implemented
until now for Blazor, and this feature brings it back as a build
building block for templated components (more to come).

In Blazor land a template like:
```
@{ RenderFragment<Person> template = @<div>@item.Name</div>; }
```

complies to code like:
```
RenderFragment<Person> template = (__builder, item) =>
{
    __builder.OpenElement(...);
    ...
    __builder.CloseElement(...);
}
```

Since the declaration always has a generic type parameter inside, it
needs to be in a context where the type is known.. ie: not with `var`.

See tests for ways to consume templates.

NOTE: There are the following caveats for templates
- Templates require a single root element.
- Templates don't work in the `@functions { }` block

These limitations are baked into the core of Razor and will take a while
for us to address (v3.0).
2018-08-31 19:10:42 -07:00
..
AsyncEventHandler_OnElement_ActionEventArgs_Lambda In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
AsyncEventHandler_OnElement_ActionEventArgs_MethodGroup In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
AsyncEventHandler_OnElement_Action_Lambda In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
AsyncEventHandler_OnElement_Action_MethodGroup In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToComponent_SpecifiesValueAndChangeEvent_WithMatchingProperties Add type checking for component parameters 2018-06-05 19:58:50 -07:00
BindToComponent_SpecifiesValueAndChangeEvent_WithoutMatchingProperties In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToComponent_SpecifiesValue_WithMatchingProperties Add type checking for component parameters 2018-06-05 19:58:50 -07:00
BindToComponent_SpecifiesValue_WithoutMatchingProperties In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToComponent_TypeChecked_WithMatchingProperties Add type checking for component parameters 2018-06-05 19:58:50 -07:00
BindToElementFallback_WithFormat_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToElementFallback_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToElementWithSuffix_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BindToElement_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BuiltIn_BindToInputCheckbox_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BuiltIn_BindToInputText_WithFormatFromProperty_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BuiltIn_BindToInputText_WithFormat_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BuiltIn_BindToInputText_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
BuiltIn_BindToInputWithoutType_WritesAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
ChildComponent_WithChildContent In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
ChildComponent_WithElementOnlyChildContent Handle ChildContent that starts with an HTML element. Fixes #875 2018-05-23 15:57:48 +01:00
ChildComponent_WithExplicitEventHandler In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
ChildComponent_WithExplicitStringParameter Add type checking for component parameters 2018-06-05 19:58:50 -07:00
ChildComponent_WithLambdaEventHandler In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
ChildComponent_WithNonPropertyAttributes In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
ChildComponent_WithParameters Add type checking for component parameters 2018-06-05 19:58:50 -07:00
ChildComponent_WithWeaklyTypeEventHandler Fix #954 - use weak typing for 'event handlers' 2018-07-05 09:15:01 -07:00
ComponentParameter_TypeMismatch_ReportsDiagnostic Add type checking for component parameters 2018-06-05 19:58:50 -07:00
Component_WithDocType Fix #1169 ignore DOCTYPE 2018-07-23 17:42:47 -07:00
Component_WithRef In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
Element_WithRef In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
EventHandler_OnElement_WithDelegate In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
EventHandler_OnElement_WithLambdaDelegate In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
EventHandler_OnElement_WithString In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
RazorTemplate_AsComponentParameter Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_AsComponentParameter_MixedContent Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_ContainsComponent Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_FollowedByComponent Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_InAttribute Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_InCodeBlock Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_InCodeBlock_Dynamic Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_InExplicitExpression Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_InImplicitExpression Add support for Razor templates 2018-08-31 19:10:42 -07:00
RazorTemplate_MultipleRoots Add support for Razor templates 2018-08-31 19:10:42 -07:00
Regression_597 In Blazor cshtml, auto-reference Microsoft.AspNetCore.Blazor and .Components (#751) 2018-05-05 17:55:08 +01:00
Regression_609 Add regression test for 609 2018-05-22 13:58:04 -07:00
Regression_772 Fix #773 (for real this time) 2018-05-14 10:47:36 -07:00
Regression_773 Fix #773 (for real this time) 2018-05-14 10:47:36 -07:00
Regression_784 Fix #784 - allow complex content for HTML 2018-05-22 11:58:46 -07:00