Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 239 Vote(s) - 3.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Since flutter 1.9 : how to run flutter app in a browser ? Flutter run -d chrome not working

#1
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 run

The command not working:

flutter run -d chrome

=> No devices found with name or id matching 'chrome'

I tried with google-chrome as device name with same result


```
[✓] Flutter (Channel master, v1.10.2-pre.38, on Linux, locale fr_FR.UTF-8)
• Flutter version 1.10.2-pre.38 at /home/rbarbe/programes/flutter
• Framework revision e6ae95c4ce (il y a 18 heures), 2019-09-11 07:46:57 -0700
• Engine revision 7ea9884ab0
• Dart version 2.5.0 (build 2.5.0-dev.4.0 be66176534)


[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /home/rbarbe/Android/Sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• Java binary at: /home/rbarbe/programes/android-studio/jre/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
• All Android licenses accepted.

[✓] Android Studio (version 3.3)
• Android Studio at /home/rbarbe/programes/android-studio
• Flutter plugin version 33.3.1
• Dart plugin version 182.5215
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)

[✓] IntelliJ IDEA Community Edition (version 2019.1)
• IntelliJ at /home/rbarbe/.local/share/JetBrains/Toolbox/apps/IDEA-C/ch-0/191.6183.87
• Flutter plugin version 35.2.2
• Dart plugin version 191.6183.88

[✓] IntelliJ IDEA Community Edition (version 2019.2)
• IntelliJ at /home/rbarbe/.local/share/JetBrains/Toolbox/apps/IDEA-C/ch-0/192.6603.28
• Flutter plugin version 39.0.5
• Dart plugin version 192.6603.23

[✓] VS Code (version 1.38.0)
• VS Code at /usr/share/code
• Flutter extension version 3.4.1

[✓] Connected device (1 available)
• CLT L29 • WCR0218315003400 • android-arm64 • Android 9 (API 28)

• No issues found!
```
Reply

#2
You need to run a server for web and will then be available at a port presumably 8080. If everything is set up correctly you can just:

webdev serve
otherwise try:

flutter packages pub global run webdev serve
Reply

#3
Have you enabled web support by `flutter config --enable-web` ?

[![enter image description here][1]][1]


> Got Reference from this [link][2]


[1]:

[2]:

[To see links please register here]

Reply

#4
Also make sure to upgrade flutter form the master instead of the stable branch
Reply

#5
you need cd to your flutter install workspace, and run:
```
git checkout master
```
Reply

#6
For these people whose `chrome` still cannot be detected even after `flutter config --enable-web`.You should check if your flutter in appropriate branch ,to list all branches, use:
> flutter channel

output may looks like this:

Flutter channels:
beta
dev
master
* stable
item with asterisk prefix indicates which branch you are in.To switch to master, try:

> flutter channel master

after that, your `flutter doctor` can list `chrome`device.
Reply

#7
If you are trying to develop web Application with dart then my suggestion is to create new Dart Project -> Angular Dart -> After successfully created angular dart -> then open terminal -> type "Webdev serve"
Reply

#8

[To see links please register here]


$ flutter channel master
$ flutter upgrade
$ flutter config --enable-web

$ flutter devices //downloads sky_engine and sdk tools then shows a list of devices including chrome

$ flutter create test_app
$ flutter run -d chrome //local host will run chrome





Reply

#9
In my case - flutter doctor gave me the following output
```
[✗] Chrome - develop for the web (Cannot find Chrome executable at google-chrome)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
```

as on arch, the binary is called google-chrome-stable and/or google-chrome-unstable

```
export CHROME_EXECUTABLE=/usr/bin/google-chrome-stable
```
was all that was needed to get it working.
Reply

#10
flutter run -d chrome --web-renderer html
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through