[DON'T MERGE YET] Add docs for .NET SDK hosting integration#694
[DON'T MERGE YET] Add docs for .NET SDK hosting integration#694adams85 wants to merge 8 commits into
Conversation
4ddc590 to
42c6f5e
Compare
Deploying configcat-docs with
|
| Latest commit: |
408a801
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://cbb73fa2.docs-xmy.pages.dev |
| Branch Preview URL: | https://dotnet-sdk-hosting-docs.docs-xmy.pages.dev |
bb9d605 to
408a801
Compare
| </TabItem> | ||
| </Tabs> | ||
|
|
||
| If your application needs to use multiple ConfigCat configs, it is possible to register additional named clients as follows: |
There was a problem hiding this comment.
It would be nice to have some info on how to obtain the client, a link or something to that part of the documentation.
Also, maybe this whole keyed part can be put into an advanced section in the documentation and here we should only link to it.
| var client = app.Services.GetRequiredService<IConfigCatClient>(); | ||
| ``` | ||
|
|
||
| Named clients can be resolved similarly, using the `FromKeyedServices` attribute or by |
There was a problem hiding this comment.
It would be nice to have a code example on how to obtain the client in a constructur with a default client and with a keyed client too.
| Alternatively, by code: | ||
|
|
||
| ```csharp | ||
| configCatBuilder.UseInitMode(new ConfigCatInitMode.WaitForClientReady(throwOnFailure: false)); |
There was a problem hiding this comment.
It would be nice to talk a bit about the throwOnFailure parameter here too.
|
|
||
| ## Sample Applications | ||
|
|
||
| Check out our Sample Applications how they use the _ConfigCat SDK_: |
There was a problem hiding this comment.
As I see the same sample apps are listed for both the DI stuff and the old one. Is this intentional?
| ## Look under the hood | ||
|
|
||
| - <a href="https://github.com/configcat/.net-sdk" target="_blank">ConfigCat .NET SDK on GitHub</a> | ||
| - <a href="https://www.nuget.org/packages/ConfigCat.Client" target="_blank">ConfigCat .NET SDK on nuget.org</a> |
There was a problem hiding this comment.
Don't we have another package for the generic host one?
Describe the purpose of your pull request
Adds docs for the new .NET SDK integration with
Microsoft.Extensions.*.Also, does some minor corrections in other SDK references.
(The errors reported by the "Validate Document" check are expected.)
Don't merge this before configcat/.net-sdk#140 is released.
Related issues (only if applicable)
https://trello.com/c/8kt5LPsU
How to test? (only if applicable)
Another version of the .NET SDK Reference has been created under the name "ASP.NET Core & DI-Based Apps". Mostly it's the same content but there are some differences in text, code samples and links.
Requirement checklist