I built a web application in Flutter and run the command flutter build web
successfully. I'm trying to find a way to deploy it on Heroku like my react applications but found nothing in Heroku documentation.
we run flutter web or static page run with the help of php.we can use many other language .we can simply use php without any more work.
First
create app in heroku after this will shown .
after run flutter build web
in the root of the project folder it will generate static content in build/web .copy the file to any other directory and open cmd like this
create two file index.php and composer.json
in index.php
add this
<?php include_once("index.html");
{}
after run the command in the
`heroku login`
heroku git:clone -a appname
git add .
git commit -am "make it better
git push heroku master
after running this it may be show any error .if not show any error run this https://appname.herokuapp.com/#/ .your website will be live.