-
-
Save bjoerntx/42a9e9e747e0e1456f10cb3cd9bc99ff to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[HttpGet] | |
public IActionResult ReplaceWord(string word) { | |
Dictionary<string, string> dict = new Dictionary<string, string>() | |
{ | |
{ "Word1", "<strong>Formatted</strong> replacement for <em>Word1</em>" }, | |
{ "Word2", "<strong>Formatted</strong> replacement for <em>Word2</em>" }, | |
{ "Word3", "<strong>Formatted</strong> replacement for <em>Word3</em>" } | |
}; | |
return dict.ContainsKey(word) ? Ok(dict[word]) : Ok(null); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment