当前位置:网站首页>Flutter mixed development module dependencies
Flutter mixed development module dependencies
2022-07-31 05:59:00 【work hard for today】
One: Create an android project.
Second: create flutter_libary
Three: configure flutter
1. The project's corresponding build.gradle
maven uses the aliyun image to prevent some finding problems.
allprojects {repositories {maven { url 'https://maven.aliyun.com/repository/public' }maven { url 'https://maven.aliyun.com/repository/public' }maven { url 'https://maven.aliyun.com/repository/google' }maven { url 'https://maven.aliyun.com/repository/gradle-plugin' }maven { url 'https://storage.googleapis.com//download.flutter.io'}}}
2. Setting.gradle corresponding to the project
setBinding(new Binding([gradle:this]))//flutter directoryevaluate(new File(settingsDir.parentFile,'flutter_library/.android/include_flutter.groovy'))
new Binding([gradle:this]) If there is an error, identify the corresponding jar [package groovy.lang.Binding;]
groovy-all-1.3-2.5.12.jar
The gradle version I use is: 7.2-bin, the corresponding file directory, there is no such file
c\Users\user\.gradle\wrapper\dists\gradle-7.2-bin\2dnblmf4td7x66yl1d74lt32g\gradle-7.2\lib\
user --> the corresponding own account name
Solution: search for other versions.Find this file in ..\gradle-6.7\lib\groovy-all-1.3-2.5.12.jar and copy it to gradle-7.2\lib\groovy-all-1.3-2.5.12.jar
Need to restart androidstudio.
Add build.gradle in the 3.app directory
implementation project(':flutter')
dependencies {...implementation project(':flutter')}
4. Create activity : FlutterActivity【Java extends】
import io.flutter.embedding.android.FlutterActivityclass FlutterActivityTest : FlutterActivity() {override fun onCreate(savedInstanceState: Bundle?) {super.onCreate(savedInstanceState)}}
Real machine running
边栏推荐
- The feign call fails, JSON parse error Illegal character ((CTRL-CHAR, code 31)) only regular white space (r
- How to distinguish big and small endian in C language
- MySQL面试题大全(陆续更新)
- mysql common commands
- cocos2d-x-3.2图片灰化效果
- cocoscreator 显示刘海内容
- 2021美赛C题M奖思路
- Detailed explanation of pointers in C language
- podspec自动化升级脚本
- C language tutorial (2) - printf and data types that come with c
猜你喜欢
DeFi Token in the project management
npm WARN config global `--global`, `--local` are deprecated. Use `--location solution
Digital twins will be an important way to enter the "metaverse"
js中的对象与函数的理解
The feign call fails, JSON parse error Illegal character ((CTRL-CHAR, code 31)) only regular white space (r
[uiautomation] Get WeChat friend list (stored in txt)
Common JVM interview questions and answers
NFT与数字藏品到底有何区别?
一文速学-玩转MySQL获取时间、格式转换各类操作方法详解
flutter 混合开发 module 依赖
随机推荐
[Cloud Native] What should I do if SQL (and stored procedures) run too slowly?
【云原生】原来2020.0.X版本开始的OpenFeign底层不再使用Ribbon了
Build vulhub vulnerability shooting range on kali
On the side of Ali, tell me what are the application scenarios of message middleware you know?
For penetration testing methods where the output point is a timestamp (take Oracle database as an example)
Linux中mysql密码修改方法(亲测可用)
DeFi Token in the project management
sql add default constraint
What is an EVM Compatible Chain?
MySQL-如何分库分表?一看就懂
【swagger关闭】生产环境关闭swagger方法
【windows】--- SQL Server 2008 超详细安装教程
What is GameFi?
小米手机短信定位服务激活失败
Chinese garbled solution in UTF-8 environment in Powershell
npm WARN config global `--global`, `--local` are deprecated. Use `--location solution
Eternal blue bug reappears
"limit" query in Oracle database
C language tutorial (1) - preparation
【uiautomation】微信好友列表获取(存储到txt中)