FEMALE TECH ENTREPRENEUR

Creating a new Flutter project

Written by Nanna Bach Munkholm

Founder & CTO Roccai

Have you ever tried creating a new Flutter project? Me neither. 

Why not do it together so you can learn from my mistakes and hopefully I can show that it’s possible to do for everyone, no matter your prior programming skills. I have been working in Flutter since November 2019 when I became head of our Flutter development in my company, DecorRaid. There are still not a lot of Flutter Developers out there and as we didn’t have money to pay for a Flutter developer, I decided to take over the development. This meant that a Flutter Developer had written the app as we had ordered and released it to the App – and Play Store. But every update or new feature to the app I had to develop. 

This was my introduction to Flutter. Just to make it clear I’m not an experienced developer – I’m self-taught and initiated my journey into programming in 2018 simultaneously with starting DecorRaid. I had experience in Python and Angular prior to starting programming in Flutter. I’m telling you this just to make it clear that it’s possible for you to begin no matter your background.

Let us get to the fun part of programming. 

Flutter is written in Dart, so that’s the programming language we are going to be working with. 

Create a new Flutter Project

I like working in VS Code so everything is going to be done using that code editer. If you haven’t already set up your code editor for Flutter, they have great documentations on that.

The first step into the world of Flutter is to install a new project.

Go to VS Code

  1. Open the Command Palette (Ctrl+Shift+P (Cmd+Shift+P on macOS)).
  2. Select the Flutter: New Project command and press Enter.
  3. Enter your desired Project name.
  4. Select a Project location.

When the project is installed add the folder to your workspace, by going to File > Add Folder to Workspace.

Now go to your folder > lib > main.dart here you will find the main code of your new app. Lets try to run the app, connect your device or simulator and press fn5 or write flutter run in the terminal.

Your code should be up and running and look something like this: 

Create a Flutter web application

One of the reasons we choose Flutter as our programming Framework for DecorRaid Swipeshop was that it support cross platform and the ability to use the same codebase for the App Store, Play Store, and web. Unfortunately, web is still in beta. But I always wanted to try it out, so let us try to make our new Flutter project ready for web. 

To enable web support run these commands in your terminal:

$ flutter channel beta

$ flutter upgrade

$ flutter config –enable-web

$ flutter devices

2 connected device:

Chrome • chrome • web-javascript • Google Chrome 78.0.3904.108
Web Server • web-server • web-javascript • Flutter Tools

$ flutter create .

$ flutter run -d chrome

That was actually, not that hard. If you have any questions or problems please reach out to me and I will see if I can help. Do you want to know what each file and folders is used for and how to structure your new application go to my post on Flutter Scalable App – Folder Structure.

Now you are ready, to code on your new Flutter project. If you don’t know what the project should be about go to the next post Choosing a Flutter project.

Have a great day and happy coding 👩🏽‍💻

Creating a new flutter project

You May Also Like…

An Elegant Puzzle: Systems of Engineering Management  – Book review

An Elegant Puzzle: Systems of Engineering Management – Book review

Gain invaluable insights into engineering management with Will Larson’s comprehensive guide. Learn practical tools and strategies for leading teams effectively, from small groups to scaling up. Discover the wisdom of stacking small wins over chasing silver bullets. An essential read for tech leaders at any level

Building an MVP for your Startup

Building an MVP for your Startup

Do you have an entrepreneur within you and want to bring it to life? Creating a business plan and building an MVP (Minimal Viable Product) is the place to start.