https://github.com/k94ll13nn3/strinken
A parametrized string library!
https://github.com/k94ll13nn3/strinken
c-sharp csharp dotnet-standard netstandard parametrized parser string strinken
Last synced: 4 months ago
JSON representation
A parametrized string library!
- Host: GitHub
- URL: https://github.com/k94ll13nn3/strinken
- Owner: k94ll13nn3
- License: mit
- Created: 2016-07-18T13:59:19.000Z (over 9 years ago)
- Default Branch: main
- Last Pushed: 2025-09-01T08:42:03.000Z (5 months ago)
- Last Synced: 2025-10-06T03:25:52.273Z (4 months ago)
- Topics: c-sharp, csharp, dotnet-standard, netstandard, parametrized, parser, string, strinken
- Language: C#
- Homepage: https://k94ll13nn3.github.io/Strinken/
- Size: 2.51 MB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Strinken
[](https://www.nuget.org/packages/Strinken/)
[](https://github.com/k94ll13nn3/Strinken/releases/latest)
[](https://raw.githubusercontent.com/k94ll13nn3/Strinken/main/LICENSE)

A parametrized string library! ([Documentation](https://k94ll13nn3.github.io/Strinken/))
## Installation
- Grab the latest package on [NuGet](https://www.nuget.org/packages/Strinken/).
## Basic example
1. Create a class that implements `ITag` for the wanted type (a class Person with a Name property for example):
``` csharp
public class NameTag : ITag
{
public string Description => "Returns the name of a Person.";
public string Name => "Name";
public string Resolve(Person value) => value.Name.ToString();
}
```
2. Create a `Parser` with this tag:
``` csharp
var parser = new Parser().WithTag(new NameTag());
```
3. Resolve a string with the parser:
``` csharp
var result = parser.Resolve("My name is {Name}.", new Person { Name = "James" });
// will return "My name is James."
```