New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Preview 4] Razor components renaming #11837
Comments
@tdykstra and I discussed this over a dozen virtual 🍺 and came up with ... Physical folder layoutEither ...
... or (root-based) ...
No consensus reached at this point. TOC
NotesConsensus thus far is that it's best to keep client-side and server-side in the same folder/under the same TOC entry as opposed to splitting Blazor client-side to client-side > spa and Blazor server-side to client-side. Current spit-ball'in yields links like 👍 ...
... which seems better than 👎 ...
cc: @danroth27, @scottaddie, @Rick-Anderson, and @wadepickett |
I don't think we want to have a top level fork between server-side and client-side Blazor. Blazor is one app model with multiple hosting models. Most of what you do with Blazor is the same regardless of whether you host client-side or server-side: you write components, add routes, inject services, etc. The only place where client-side vs server-side should come up is when your talking about different hosting. We want one doc TOC for Blazor, not two. |
I would rename the razor-components folder to blazor. The razor components tutorial should become the new Get Started with Blazor tutorial, which shows getting started with the server side model since that's what's shipping first. I think we will then need to add some content to this tutorial that highlights where you need to do something different if you want to run on WebAssembly instead. |
Similar then to what we originally had on blazor.net. Physical folder layoutEither ...
... or (root-based) ...
@tdykstra's call on that. My recommendation is that with a client-side folder it seems logical to it to go there, not be root based. TOC
|
Easy if/when ...
Otherwise, it gets dicey ... e.g. #11953 ... but not necessarily super bad. Just need to be careful. |
Sounds good, let's go with that. |
Hold on 😄 Note that we already have an aspnetcore/razor-components folder with all of the relevant Blazor content. It seems logical to rename that folder to blazor. There is also a blazor folder under client-side/spa. Anything important from that folder should be somehow merged into the top level blazor folder. |
Yes ... but it will be a rename and move. "razor-components" is currently at the root of the repo. |
btw - We aren't messing with redirects during preview. (I knew this was going to happen, so I said to the team, "Let's not bother with that until RTM.") |
It could go either way -- we have MVC and Razor Pages at top level in the folder structure but under Web apps in the ToC, so Blazor could go top level in the folder structure and under client side in the ToC |
🤔 ... root permits locations to carry "server-side" better.
... is better than ...
|
@tdykstra Per offline chat with @danroth27 ... latest i-dears: TOC Place the Blazor node directly under Web Apps (not under Client-side Development). Client-side Development > SPA > Blazor is going 👋 adios 👋. Place the Client-side Development node directly under Web Apps (i.e., it won't be on the root of the TOC). Physical Leave the If you and DR proceed with the TOC updates, let me know if you want me to take care of both. I'll get the Blazor stuff; do you want me to also take care of the Client-side update at the same time if that turns out to be the direction? [Noting that there are no physical folder shifts for Client-side; therefore, no redirects required ... just TOC updates.] Next, I'm going to update the opening post of this issue with the latest. It will include the other details on the topic work for Blazor P4. |
These all make sense to me, as does including them in your PR. Web apps node will have a long list, we'll have to give some thought to the right order. |
@tdykstra When you determine the order, I recommending updating the OP on this issue. I intend to work from the OP when the time comes, so I've been keeping it updated with latest guidance. |
OP? |
original post ...... aka first comment Where did I get that from? ... AOL??!! 🙈 |
Ok I added placement suggestions in the main comment box. |
For Preview 4 RTM
dotnet/aspnetcore#8931
Because sample and code example updates are concurrent with the naming changes, this should be worked the day that Preview 4 releases.
Details:
services.AddRazorComponents()
->services.AddServerSideBlazor()
routes.MapComponentHub<TComponent>()
->routes.MapBlazorHub<TComponent>()
components.server.js
back toblazor.server.js
andcomponents.webassembly.js
back toblazor.webassembly.js
.Additional Info:
Convo on this issue resolves to ...
Physical folder layout
client-side
>spa
>blazor
👋 Bye! 👋TOC
Client-side Development > SPA > Blazor 👋 Bye! 👋
The text was updated successfully, but these errors were encountered: