No option for adding New flutter Web Project in IntelliJ Dart Templates !!! Also tried Vs code, is asking for Which Dart template - intellij-idea

I'm trying to start a new Flutter project in Intellij as well as Vs code.
Intellij there is no option provided to add a new flutter web project in Dart templates.
Vs code whenever I select New flutter Web Project after accepting the stagehand it asks for the Dart template which is why I'm stuck.??
Please help soon??

Since flutter 1.9 flutter_web is merged inside flutter, Follow the below steps to create and run your first flutter web App through IntelliJ IDEA.
Create a new flutter project.
Now change your flutter channel to master using flutter channel master
Upgrade flutter flutter upgrade
Install the flutter_web build tools flutter pub global activate webdev
Enable flutter web using flutter config --enable-web
Check available devices flutter devices and you will get a result like:
Chrome • chrome • web-javascript • Google Chrome 81.0.4044.92
Web Server • web-server • web-javascript • Flutter Tools
Inside your flutter project create myapp using flutter create myapp
Navigate inside myapp using cd myapp
Finally, run flutter run -d chrome
And you will be able to run your flutter web app into chrome. Hurray 🤟🏽🤟🏽🥳
Reference links: Building a web application with Flutter , flutter_web

It seems that the support for Flutter Web Apps was dropped in stagehand (that contains the dart templates). From this commit on github: (Dropping Flutter Web sample). Instead, this wikipage shows how to migrate/create a web package in flutter from command line.

Create your project from command-line.
Check out this tutorial. flutter.dev/docs/get-started/web
Then just open the project in IntelliJ IDE.

Install or Update the dart and flutter plugins in Intellij and/or VS Code
For Intellij
Go to [mac] Preferences>Plugins>Marketplace and search for Dart and Flutter, install it.
For VS Code
Go to View > Command Pallet and type in Extensions: Install Extensions
then type flutter and install it
Its well documented in this link
Setup Flutter

Related

Expo developer tools option is missing

When I start my project using command expo start , Expo is starting the Metro bundler but not opening the developer tool. Also developer tool option is not available in commands menu.
I suppose there should be command option : 'd' which will launch the developer tool on the localhost:19002 but it's not coming for me.
Using expo cli version 5.4.4
Developer tools removal
Since the release of expo-cli#6.0.0 the expo team has decided to discontinue the Web UI they had put in place. You can find more details about this in this blog post.
All of the actions that could be done within the Web UI can be done within the command line interface. For example, one used to be able to change connection mode directly within the UI :
Now to start expo in --tunnel mode you would have to have ngrok installed on the new expo version npm i -g #expo/ngrok and to run npx expo start --tunnel. Details on the CLI can be found in the docs here.
Accessing the Developer tools anyway
If you still wish to use the developer tools web UI, there are two options :
Use an older version of the expo sdk (~44.0), to do so you could use expo-cli#5.0.2 which is linked to that sdk. However, it is not recommended to stay on older versions which will be discarded at some point.
Use your own Web UI. Here is the source code from expo's original Web UI which you can use a base. There are likely over repos out there which fit this purpose.
If you're using a library such as react-navigation or anything (or itself) the relies on reanimated you won't be able to use remote debugging. https://docs.expo.dev/versions/latest/sdk/reanimated/
After changing the expo sdk version from 45.0.4 to 44.0.6, I am able to see the Developer tools running on http://localhost:19002.

How to integrate an external app into IntelliJ plugin?

I want to build an Android Studio plugin (IntelliJ plugin) which can open an external app by pressing the button. The external app is developed by myself and is quite small. I hope to integrate it to the IntelliJ plugin so users only need to install the plugin instead of installing the app explicitly.
So is it possible for me to package the app into the plugin? I have tried putting the .app file under the resources folder but I don't know how to open the app programmatically. Or is there any other way to achieve my purpose?

Implicit PendingIntent Vulnerability error from Google Play Store

Problem Describe:
Recently, some developers have reported that they want to update their app(s) on Play Store,
However, it receives rejection from Google with the title Implicit PendingIntent Vulnerability, said that their app(s) contain an Implicit PendingIntent issue. And they need to fix this issue before the deadlines shown in their Play Console, or app(s) may be removed from Google Play.
Similar Question: Google denied update due Remediation for Implicit PendingIntent Vulnerability
As#tao mentioned, let me post the solution here.
Problem Reason:
HMS Core Push kit earlier than 5.3.0.304 version、Analytics Kit earlier than 6.0.0.301 version and Account kit earlier than 5.3.0.305 version contain the Implicit PendingIntent issue.
Solution:
Push Kit SDK version 5.3.0.304、Analytics Kit SDK version 6.0.0.301 and
Account kit SDK version 5.3.0.305 have been released and fixed the Implicit PendingIntent issue. They've been tested and verified by developers and can be approved by Google for release.
If you are currently using the plug-in(such as React Native, Cordova, Ionic,Flutter), Before the new version of those plug-in released, Huawei also provide a workaround solution(By manually changing the version number).
The following describes the modification method (based on the 5.x plug-in):
React Native:
After the HMS Core plug-in is installed in the RN, the plug-in package is stored in node_modules/#hmscore.
You need to modify the build.gradle file in the node_modules/#hmscore/react-native-hms-account/android directory (taking the Account Kit plug-in as an example):
Open the build.gradle file and change the SDK version in dependencies.
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'com.facebook.react:react-native:+' // From node_modules
implementation 'com.huawei.hms:hwid:5.0.3.302'
}
After the update, run the following command to start compilation again. The plug-in downloads the new SDK:
react-native run-android
Cordova/Ionic
If you have installed the plugin as Huawei document describred, the plugin should be saved in node_modules/#hmscore folder.
You need to modify the plugin.xml file in the node_modules/#hmscore/cordova-plugin-hms-push directory. (The following uses the Push Kit plug-in as an example)
Open the Plugin.xml file, search for the keyword framework, and find the SDK to be modified.
<framework src="androidx.core:core:1.3.1"/>
<framework src="com.facebook.fresco:fresco:2.2.0"/>
<framework src="com.huawei.hms:push:5.0.2.301" />
<framework src="resources/plugin.gradle" custom="true" type="gradleReference"/>
Change the version number to the new one and save it.
Go back to the application root directory and delete the platforms/android and plugins/cordova-plugin-hms-push folder.
Run the following command in the root directory:
Cordova:
cordova platform add android
cordova run android --device
Ionic(Cordova):
ionic cordova platform add android
ionic build
ionic cordova run android --device
Ionic (Capacitor) operates in different ways:
①. Delete the capacitor-cordova-android-plugins folder from the android directory.
②. Modify the plugin.xml file according to the description in step 2.
③. Run the following command:
ionic build
npx cap sync
npx cap open android
④. Recompile in the Android Studio
Flutter
You may refer to this answer.
Summary
The plug-ins above are used in open source mode, so developers can modify them directly.
However, the Xamarin plug-in is published in Nuget Package mode. Therefore, you cannot modify the SDK version. If this problem occurs, please feel free to contact us.

A dummies guide to installing a PhoneGap plugin

I am trying to build a basic QR code scanning app but I am not exactly sure how to add a plugin. I am trying to install - https://www.npmjs.com/package/cordova-plugin-barcodescanner
I have installed NPM, GIT and Cordova, and have deployed a Framework 7 based app from the phonegap software that has the following directory:
C:\Users\user\Documents\Phonegap Apps\Saving Energy\Android
I am unsure how to install the plugin? Do I run
npm i cordova-plugin-barcodescanner
in Windows Command Prompt, and if so do I have to change the directory to my app plugin folder? Do I run it using node.js? Etc.
You can add plugin easily using cordova
you should open command prompt with Saving Energy as directory and run
cordova plugin add [cordova-plugin-name]
For your case it is
cordova plugin add cordova-plugin-barcodescanner
Hope it Helps!

Dart SDK version error when getting dependencies

I'm trying to add the http and image Dart packages. After adding the dependencies in pubspec.yaml and attempt to "Get dependencies", I'm getting the version error.
I have attempted "Check for Update" in IntelliJ, reinstall Flutter and Dart plug in in IntelliJ, redownload Flutter, and ran "flutter upgrade" in Flutter Console, with no luck. It seems the Dart SDK that comes with Flutter has not been updated.
I was able to download later version of Dart SDK independently, but if I just drop the dart-sdk folder of a newer version into the Flutter folder, I get more error still.
How can I update the Dart SDK in the Flutter package, so I can add dependencies?
The reason was flutter console being in the beta channel, causing flutter to not upgrade to latest version. Fix was flutter channel dev then flutter upgrade in console.