Created
November 28, 2017 23:13
-
-
Save hudo/8ea171e14d5d4f2502f1c6b9d5b5d1a6 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
internal class LinkDecorator : IRenderable | |
{ | |
private readonly IRenderable _inner; | |
private readonly string _url; | |
public LinkDecorator(IRenderable inner, string url) | |
{ | |
_inner = inner; | |
_url = url; | |
} | |
public string Render() => $"<a href=\"{_url}\">{_inner.Render()}</a>"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment