Questions tagged [flutter-web]

Questions related to Flutter for web support – currently (as of January 2021) is available on the beta channel. Flutter supports the generation of web content rendered using standards-based web technologies: HTML, CSS and JavaScript. With web support, you can compile existing Flutter code written in Dart into a client experience that can be embedded in the browser and deployed to any web server.

Flutter for web is a code-compatible implementation of Flutter that is rendered using standards-based web technologies: HTML, CSS and JavaScript. With web support, you can compile existing Flutter code written in Dart into a client experience that can be embedded in the browser and deployed to any web server.

4374 questions
93
votes
16 answers

Flutter web can't load network image from another domain

I can't load network images in flutter web from other domains with API calls. getting this error Trying to load an image from another domain? Find answers at: https://flutter.dev/docs/development/platform-integration/web-images ImageCodecException:…
Abel Ayalew
  • 1,603
  • 1
  • 7
  • 12
84
votes
9 answers

How to remove hash (#) from URL in Flutter web

The default URL of a Flutter web project defines a URL containing a hashtag (#), as follows: http://localhost:41521/#/peaple/... I would like to remove this '#', looking like this: http://localhost:41521/peaple/ How can I solve this problem?
Edeson Bizerril
  • 1,595
  • 1
  • 11
  • 12
71
votes
9 answers

Flutter-Web: Mouse hover -> Change cursor to pointer

UPDATE (2021/05/11): Flutter now natively has Hover Events implemented Widgets. There is a MouseCursor for Widgets like RaisedButton and properties like hoverColor or…
Daniel Eberl
  • 1,268
  • 1
  • 10
  • 22
64
votes
6 answers

How to specify a port number while running flutter web

Is there any way to start Flutter web, with a Headless-Server target, always on the same specified port number ? Today, running the web application with: flutter run -d headless-server Provides a random port number.
Omar BELKHODJA
  • 1,622
  • 1
  • 12
  • 18
57
votes
3 answers

How to import platform specific dependency in Flutter/Dart? (Combine Web with Android/iOS)

I am using shared_preferences in my Flutter application for iOS and Android. On the web I am using the http:dart dependency (window.localStorage) itself. Since Flutter for web was merged into the Flutter repo, I want to create a cross platform…
gi097
  • 7,313
  • 3
  • 27
  • 49
54
votes
6 answers

How to deploy flutter web on server?

I was learning Flutter web. Now I want to deploy this code in the real server. The flutter code here: in the lib folder void main() => runApp(new MyApp()); class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { …
John
  • 2,633
  • 4
  • 19
  • 34
51
votes
10 answers

Flutter WEB download option

I am making flutter web app that should generate a file from user data. And have the option to download the output file. But I can not find any options/packages which works for flutter web :( Can someone please help me out?
Pratik
  • 741
  • 1
  • 6
  • 8
51
votes
9 answers

How can a named route have URL parameters in flutter web?

I'm building a web-app which needs to have a route that gets a post ID and then it will fetch the post using the ID. How can I have URL arguments let's say /post/:id so id is the argument My app looks like that currently: class MyApp extends…
TheOnlyArtz
  • 529
  • 1
  • 4
  • 8
51
votes
10 answers

How to Pick files and Images for upload with flutter web

I would like to know how to pick an Image from the users computer into my flutter web app for upload
Norbert
  • 6,874
  • 14
  • 40
  • 65
50
votes
5 answers

Plugin project :location_web not found. Please update settings.gradle. How do I fix this?

I was using the google maps api and location pub,dev package in my android flutter app, and tried to bring up an image using the url from the api. This was the url with some code: class LocationHelper{ static String mapviewpointer({double…
47
votes
10 answers

Dart/Flutter Web unit testing errors: Error: Not found: 'dart:html'

I'm working on a Flutter web app and I'm having trouble running a test. Flutter 1.7.8+hotfix.4 • channel stable • git@github.com:flutter/flutter.git Framework • revision 20e59316b8 (9 weeks ago) • 2019-07-18 20:04:33 -0700 Engine • revision…
skillit zimberg
  • 1,024
  • 1
  • 14
  • 22
47
votes
10 answers

Since flutter 1.9 : how to run flutter app in a browser ? Flutter run -d chrome not working

Since flutter 1.9 flutter_web is merged inside flutter. I'm trying to run the initial flutter app in a chrome browser but it fails. OS is ubuntu 19.04 The command I used with success: flutter upgrade flutter create test_1_9 cd test_1_9 flutter…
hawkbee
  • 1,442
  • 3
  • 18
  • 26
45
votes
17 answers

Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable. Flutter 2.0

I updated My flutter Version from 1.22 to 2.0. There are some errors in Flutter Doctor. How Could I solve this. That happen Afer Updated my Flutter Version. I am Using Android Studion 4.1.2, Ubuntu 20.04.2 LTS(64 bit)
Kasun Hasanga
  • 1,626
  • 4
  • 15
  • 35
44
votes
4 answers

How to convert Uint8List image to File Image for upload in flutter web

I have have been able to pick a file from my computer and display in my flutter web app. I have a function(of type File) which takes a file and uploads it to the server. like so functionName(File imageToSend). But when I try to send this image to…
Norbert
  • 6,874
  • 14
  • 40
  • 65
44
votes
10 answers

How do I open an external url in flutter web in new tab or in same tab

I have a simple web app I have created with flutter web. I would like to know how I can open new an external url either in a new tab or in the same tab in my flutter web app. say I want to open the url https://stackoverflow.com/questions/ask
Norbert
  • 6,874
  • 14
  • 40
  • 65
1
2 3
99 100