Posts

Showing posts with the label Project Template

Experimenting with AI to Generate a Vertical Slice Folder Structure in a Blazor App

Image
Today, I set out to generate a Vertical Slice Architecture (VSA) folder structure inside a default Blazor template using AI tools. I ran this experiment inside Visual Studio 2022 using Copilot in Agent Mode. My goal was to automate the restructuring of a Blazor app into a cleaner, feature-based format aligned with the VSA pattern. Attempt 1 – Claude 3.7 I began by prompting Claude 3.7. Unfortunately, the results were underwhelming. Despite giving a detailed prompt, it added the MediatR NuGet package—something I never asked for—and failed to restructure the file layout at all. It completely ignored the organizational aspects and made assumptions about architecture that weren’t part of the task. Attempt 2 – Gemini 2.5 Next, I gave Gemini 2.5 a try. This attempt ended abruptly with an error—it didn’t return anything meaningful. At this point, I was beginning to wonder if AI was the right approach for this task. Attempt 3 – ChatGPT 4.0 Then I tried ChatGPT 4.0. It didn’t modify anyt...

Brand New Default Blazor Templates

Image
 I have made the decision to switch to using TailwindCss for all my new projects because I really like  TailwindCss . It became a pain to have to clean out the Bootstrap and add the styling for the default pages each time I started a new project. My solution, create a new default Blazor default template that uses TailwindCss. Ways to create templates After some investigation, I discovered there are now two ways to create project templates for .Net. The original one where you use Visual Studio to token your project and then export it out. The second method is to use the template engine. Using Visual Studio is error-prone. Once you tokenize your project, it will not build anymore. You will have to keep two versions of the project and update each one moving forward. It does generate a zip file which makes it easier to share the new template. The new and better way, in my opinion, is to use the new template engine. Channel 9 has a good video series  on how it works. You use t...