Skip to content

Commit 7e11aa4

Browse files
committed
✏️ update type annotations in README examples for clarity and consistency
1 parent 9e9418d commit 7e11aa4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@ dotnet add package QsNet
5858
using QsNet;
5959

6060
// Decode
61-
var obj = Qs.Decode("foo[bar]=baz&foo[list][]=a&foo[list][]=b");
61+
Dictionary<string, object?> obj = Qs.Decode("foo[bar]=baz&foo[list][]=a&foo[list][]=b");
6262
// -> { "foo": { "bar": "baz", "list": ["a", "b"] } }
6363
6464
// Encode
65-
var qs = Qs.Encode(new Dictionary<string, object?>
65+
string qs = Qs.Encode(new Dictionary<string, object?>
6666
{
6767
["foo"] = new Dictionary<string, object?> { ["bar"] = "baz" }
6868
});
@@ -77,11 +77,11 @@ var qs = Qs.Encode(new Dictionary<string, object?>
7777

7878
```csharp
7979
// Decode
80-
var decoded = Qs.Decode("a=c");
80+
Dictionary<string, object?> decoded = Qs.Decode("a=c");
8181
// => { "a": "c" }
8282
8383
// Encode
84-
var encoded = Qs.Encode(new Dictionary<string, object?> { ["a"] = "c" });
84+
string encoded = Qs.Encode(new Dictionary<string, object?> { ["a"] = "c" });
8585
// => "a=c"
8686
```
8787

0 commit comments

Comments
 (0)