Study notes-after uni-app is packaged, uni.showToast cannot be displayed in the app

After completing the uni-app project, package it into the Android version of the app software. Sometimes there is a problem that uni.showToast cannot be displayed. If the content in uni.showToast() can be displayed normally on the web side, but cannot be displayed on the app side, it may be that the configuration when packaging is wrong. The solution is as follows:


method:

1. Find the manifest.json file of the project and click to enter.

2. Find the App permission configuration option.

3. Check the option <uses-permission android:name="android.permission.GET_TASKS" />.

As shown in the figure:

 


The above is the solution to this problem.

Guess you like

Origin blog.csdn.net/qq_41339126/article/details/113132492