Search code examples
flutterdartcode-generationmobile-application

Is there a way to create a new flutter project with some folder or file generated


So I've been creating a lot of flutter apps for freelance projects. However, I have some setup where I created a lot of folders and dart files such as constant, utils and so on. After that, I start writing the same code for a certain file such as the error page and loading widget. So how can I generate all of this since it takes 1 hour for me to finish setup the architecture and actually start the project?


Solution

  • Take a look at Mason which can create "bricks" of templated dart code and other files. You can create a personal favorite "create a project" brick, or even just add items to an existing project.