Skip to content
This repository has been archived by the owner on Dec 4, 2021. It is now read-only.
/ migrate_to_web Public archive

Migrate your current Flutter projects to Flutter for Web projects

License

Notifications You must be signed in to change notification settings

timtraversy/migrate_to_web

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Migrate To Web

pub package

Dang

It looks like with a recent update you can now just run flutter create . in your project to make it web compatible, according to this. But if you are still interested, read on!

Automatially migrate your current Flutter projects to be compatible with Flutter Web. The current workflow suggested by the Flutter team is to create a copy of your app's code and change it according to their migration guide. This tool automates all those steps and creates a nice little Flutter Web project out of your current one.

How To use it

From the root of your flutter project run

flutter pub run migrate_to_web

This will automatically create a project in the same parent directory with the suffix _web.

To use a different name for the web project, use the argument -n or --name.

flutter pub run migrate_to_web -n my_web_project

If you make changes to your project, just run the same command and it will update the web project.

To finish the project set up, all you need to do is run flutter packages get in that directory, and upload any font files you were using into the fonts folder

To-do

  • Handle fonts
  • Handle assets
  • Add tests for updating situations

PRs & issues welcome 😛

About

Migrate your current Flutter projects to Flutter for Web projects

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published