Add name/description values for InjectDirective

This commit is contained in:
Steve Sanderson 2018-02-22 23:44:25 +00:00
parent 8ff4cee323
commit e1aab02228
1 changed files with 2 additions and 4 deletions

View File

@ -23,10 +23,8 @@ namespace Microsoft.AspNetCore.Blazor.Razor
DirectiveKind.SingleLine,
builder =>
{
builder.Tokens.Add(DirectiveTokenDescriptor.CreateToken(
DirectiveTokenKind.Type, optional: false));
builder.Tokens.Add(DirectiveTokenDescriptor.CreateToken(
DirectiveTokenKind.Member, optional: false));
builder.AddTypeToken("TypeName", "The type of the service to inject.");
builder.AddMemberToken("PropertyName", "The name of the property.");
builder.Usage = DirectiveUsage.FileScopedMultipleOccurring;
builder.Description = "Inject a service from the application's service container into a property.";
});