Skip to content

Blazor WASM config file+other providers updates#18127

Merged
guardrex merged 4 commits intomasterfrom
guardrex-patch-3
May 4, 2020
Merged

Blazor WASM config file+other providers updates#18127
guardrex merged 4 commits intomasterfrom
guardrex-patch-3

Conversation

@guardrex
Copy link
Copy Markdown
Collaborator

@guardrex guardrex commented May 4, 2020

Fixes #18088

Thanks @paul-wade 🎸 and @conficient 🎷!

This fixes an obvious blunder where I had paragraphs at first (<p>) for example output then switched to list items (<li>) but didn't get all of the tags updated. I was rushing and didn't test. The IDE would have issued an instant 💀 death threat 💀 for that. Anyway ...

Although I wasn't asked to show loading a non-default app settings file, 🤔 I think we have to have it. Devs are very likely going to want to have other config files and want them to ✨ Just Work!™️ ✨. Without being able to just toss a File Configuration Provider in there, they'll be stuck and wondering how to do it. Therefore, I tack on a brief example at the end of the section on this PR. Thanks again @conficient ... nice bit there.

Another problem here that's unresolved on the PR is that we're saying, 'Just go over to the ASP.NET Core Fundamentals > Configuration Provider topic and use anything you like.' Well ... Nope! 😄 ... That's just not true. Two options:

  • We can remove the mention of using general config providers, at least for the time being. We need a lower-priority follow-up issue to track dealing with this problem later.
  • We can actually say which ones work OOB/as-expected and which ones either don't work or work with special configuration.

How shall we proceed?

@guardrex guardrex requested a review from captainsafia May 4, 2020 13:56
Copy link
Copy Markdown
Contributor

@captainsafia captainsafia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oof! Thanks for following up on the user feedback here, Luke.

Your point in the other comment about us linking to the ASP.NET docs on configuration providers being too catch all is prudent.

ASP.NET does not require that you can SetBasePath on the ConfigurationBuilder before requesting files via a relative path, so our configuration differs in this way.

The example using HTTPClient works. I'll see if I can cook something up to extract files from non-wwwroot directorie (if that's possible).

@guardrex
Copy link
Copy Markdown
Collaborator Author

guardrex commented May 4, 2020

I think temporarily that we should tone down this idea about sending readers to that topic ... I mean until we can say which ones work OOB with WASM. I'll open an issue to address it further, but I'm going to make it a P2 (Medium) given all of the work I have on my plate for the next few weeks (e.g., security ... let's see .......... security ........ and uh ... oh, yeah! I almost forgot .... SECURITY! 😄).

see if I can cook something up to extract files from non-wwwroot directorie (if that's possible).

If you come up with anything, I'll have an 👁️ out for your issue.

@guardrex
Copy link
Copy Markdown
Collaborator Author

guardrex commented May 4, 2020

Ok, I opened #18134 to work on it later.

@guardrex guardrex merged commit 0306fec into master May 4, 2020
@guardrex guardrex deleted the guardrex-patch-3 branch May 4, 2020 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clarify wording of default appsettings.json loading.

2 participants