Awesome, Daniel! I have been searching the web to find a way to create a dynamic component such as a typeof Select tag and pass the options as parameters on the fly. In other words, define the child components through the parameter list rather than using a predefined component. Is this possible?
can you please explain about why do we have @rendermode interactive server in counter component and also what is the use of attribut stream rendering in weather component 🤔🤔
can you help me out from here make code changes in Counter.razor file but its not trigerring in counter page i mean in browser it showing me home i manually go to counter page then all change are appear their like what i mean to say when you run the program in browser it goes home component not Counter Hope you reply fast ... :) please
I do find this Components folder somewhat confusing, where do you put reusable or shared components, there doesn't seems to be any concept of these in the project or anywhere specified to put them, the layout is shared component across all pages but yet it's not shown as shared in the project structure.
I believe you may freely create your own directory within Components. You can name the folder "Shared" (or anything that makes sense), then when creating a new shareable component, we can just place it in that folder and then use the components in ways we see fit. (edit: typo)
@@kenlayug I am aware of that, I'm just wonding why the existing shared components are not in a shared folder. Like I previously said I find this somewhat confusing.
@@TrOgaN_ the razor components you are talking about are the counter and weather. the reason why they are in Pages folder because they are technically used as a page in the template project. Counter is routed to /counter, and weather is routed to /weather. But, even though they are used as pages to the project, you may still use them as razor components of their own (since they are all technically a .razor component file), and I think that's the point of why the template looks like that and why most beginner courses will you could add in Home.razor. I think it is just for demonstration that everything is a razor component. Just that, ofc, don't create a razor component page that you would end up use as a component for other pages. I believe in React you could do this as well. (a component as a page and component as itself) In practice, if we're creating a razor component that is a page of its own (in other words, has the @page directive and route), then Pages is the right place to put it. But if we're creating a razor component that could be used repeatedly in many pages, then we may consider creating a Shared folder and place the created razor components there.
@@TrOgaN_ As long as they are available to the final assembly, that's all that is required. Putting them within a strictly defined 'Shared' folder in a single solution forces 'form' over 'function' when that solution may actually generate an assembly itself which is then imported into other assemblies for use (i.e. MudBlazor or other component 'libraries'). You can create your own desired hierarchy / naming for all the components you want to create... As long as they are reachable to the final assembly, they will just work.
@@bevanweiss522 This is a rediculous answer, you are arguing that code does not need to be structured in the project, wow! I wouldn't like to be the one amending any of your code. Why have a pages folder or a components folder.
wow this is seems really straightforwrd. can't wait to get learning. :)
Awesome, Daniel! I have been searching the web to find a way to create a dynamic component such as a typeof Select tag and pass the options as parameters on the fly. In other words, define the child components through the parameter list rather than using a predefined component. Is this possible?
can you please explain about why do we have @rendermode interactive server in counter component and also what is the use of attribut stream rendering in weather component 🤔🤔
Nice Tutorial!
can you help me out from here make code changes in Counter.razor file but its not trigerring in counter page i mean in browser it showing me home i manually go to counter page then all change are appear their like what i mean to say when you run the program in browser it goes home component not Counter
Hope you reply fast ... :) please
I do find this Components folder somewhat confusing, where do you put reusable or shared components, there doesn't seems to be any concept of these in the project or anywhere specified to put them, the layout is shared component across all pages but yet it's not shown as shared in the project structure.
I believe you may freely create your own directory within Components. You can name the folder "Shared" (or anything that makes sense), then when creating a new shareable component, we can just place it in that folder and then use the components in ways we see fit. (edit: typo)
@@kenlayug I am aware of that, I'm just wonding why the existing shared components are not in a shared folder. Like I previously said I find this somewhat confusing.
@@TrOgaN_ the razor components you are talking about are the counter and weather. the reason why they are in Pages folder because they are technically used as a page in the template project. Counter is routed to /counter, and weather is routed to /weather.
But, even though they are used as pages to the project, you may still use them as razor components of their own (since they are all technically a .razor component file), and I think that's the point of why the template looks like that and why most beginner courses will you could add in Home.razor. I think it is just for demonstration that everything is a razor component. Just that, ofc, don't create a razor component page that you would end up use as a component for other pages. I believe in React you could do this as well. (a component as a page and component as itself)
In practice, if we're creating a razor component that is a page of its own (in other words, has the @page directive and route), then Pages is the right place to put it. But if we're creating a razor component that could be used repeatedly in many pages, then we may consider creating a Shared folder and place the created razor components there.
@@TrOgaN_ As long as they are available to the final assembly, that's all that is required.
Putting them within a strictly defined 'Shared' folder in a single solution forces 'form' over 'function' when that solution may actually generate an assembly itself which is then imported into other assemblies for use (i.e. MudBlazor or other component 'libraries').
You can create your own desired hierarchy / naming for all the components you want to create... As long as they are reachable to the final assembly, they will just work.
@@bevanweiss522 This is a rediculous answer, you are arguing that code does not need to be structured in the project, wow! I wouldn't like to be the one amending any of your code. Why have a pages folder or a components folder.
Does anyone know what browser was used in the video?
Microsoft edge
I don't even have counter.razor.cs file?
5:29
hi what is the best web server to host blazor server side application, iis?
Amazon EC2
Kestrel on Linux, the default