Skip to content

Commit 34255d0

Browse files
authored
docs: fix code for mappings
1 parent c0008f1 commit 34255d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/_docs/feature-mappings.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Once registered, mappings can be applied directly in templates by referencing th
2222
```csharp
2323
var factory = new FileBasedTemplateEngineFactory();
2424
var engine = factory.GetByTag(tag);
25-
engine.AddMappings("greetings", new Dictionary() { {"french", "Bonjour"}, {"english", "Hi"}, {"spanish", "Ola"} })
25+
engine.AddMappings("greetings", new Dictionary<object, string>() { {"french", "Bonjour"}, {"english", "Hi"}, {"spanish", "Ola"} })
2626
```
2727

2828
Assume the model contains a property *Language*, and a dictionary named *greetings* has been registered to provide translations. The following examples demonstrate how to apply mappings across different template engines:

0 commit comments

Comments
 (0)