dwyl / dwyl/learn-flutter

Flutter No devices available

Open
#14 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
98
Forks
10
PR merge metrics
No merged PRs in 30d

Description

While attempting to build a Flutter Web Application #9 on my Mac #13 I was unable to get the Google Chrome browser to be recognised as a device in Flutter ...

After a bit of googling I found: **[Web] 'flutter devices' does not list chrome** https://github.com/flutter/flutter/issues/40232
where @chenfei-io (Son Goku ;-) recommends the following steps: https://github.com/flutter/flutter/issues/40232#issuecomment-530324689

> ```
> flutter channel master
> flutter upgrade
> flutter config --enable-web
> cd
> flutter create .
> flutter run -d chrome
> ```
>
> https://flutter.dev/docs/get-started/web

Another 200Mb ... 🙄 (_this framework is **really** not for people who are bandwidth constrained!!_)
![image](https://user-images.githubusercontent.com/194400/72206080-ad3b6d80-3481-11ea-8fe8-4c9dedcbece0.png)

```
"learn-flutter" is not a valid Dart package name.

See https://dart.dev/tools/pub/pubspec#name for more information.
```
https://dart.dev/tools/pub/pubspec#name
Fix: replace hyphens for underscores.

![image](https://user-images.githubusercontent.com/194400/72206158-6d28ba80-3482-11ea-84ba-cb840ded6966.png)

Now when I execute the command `flutter run -d chrome` I see:
![image](https://user-images.githubusercontent.com/194400/72206169-96e1e180-3482-11ea-8434-cd839d635666.png)

![Screenshot 2020-01-11 at 14 57 04](https://user-images.githubusercontent.com/194400/72206181-ba0c9100-3482-11ea-86df-32435f4f2c0f.png)

Now when I run `flutter devices` I see:
```
3 connected devices:

Pixel 3 • 89HX09YMG • android-arm64 • Android 10 (API 29)
Chrome • chrome • web-javascript • Google Chrome 79.0.3945.117
Web Server • web-server • web-javascript • Flutter Tools
```

🚀

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.