GithubHelp home page GithubHelp logo

tchigher / flutter_template Goto Github PK

View Code? Open in Web Editor NEW

This project forked from xuexiangjys/flutter_template

0.0 0.0 0.0 131 KB

Flutter空壳模板工程,已搭建基础框架,实现国际化、主题换肤、登录注册等功能,可在此基础上简单修改实现自己的应用功能。

License: Apache License 2.0

Kotlin 0.38% Ruby 3.07% Swift 0.36% Objective-C 0.03% Dart 96.16%

flutter_template's Introduction

flutter_template

Flutter空壳模板工程,已搭建基础框架,实现国际化、主题换肤、登录注册等功能,可在此基础上简单修改实现自己的应用功能。

关于我

github csdn 简书 掘金 知乎

效果

效果

运行

  • 查看一下版本号是否正确
flutter --version
  • 运行以下命令查看是否需要安装其它依赖项来完成安装
flutter doctor
  • 运行启动您的应用
flutter packages get 
flutter run

项目集成介绍

本项目精选了目前Flutter最实用的几个库,可大大提高开发的效率。

使用指南

1.克隆项目

git clone https://github.com/xuexiangjys/flutter_template.git

2.修改项目名(文件夹名),并删除目录下的.git文件夹(隐藏文件)

3.使用AS或者VSCode打开项目,然后分别修改flutter、Android、ios项目的包名、应用ID以及应用名等信息。

Flutter目录修改

  • 修改项目根目录pubspec.yaml文件, 修改项目名、描述、版本等信息。

【注意】这里修改完pubspec.yaml中的name属性后,flutter项目的包名将会修改,这里我推荐大家使用全局替换的方式修改比较快。例如我想要修改nameflutter_app,在VSCode中你可以选择lib文件夹之后右击,选择在文件夹中寻找, 进行全局替换:

  • 修改lib/core/http/http.dart中的网络请求配置,包括:服务器地址、超时、拦截器等设置

  • 修改lib/core/utils/privacy.dart中隐私服务政策地址

  • 修改lib/core/utils/xupdate.dart中版本更新检查的地址

Android目录修改

  • 修改android目录下的包名。

在VSCode中你可以选择android文件夹之后右击,选择在文件夹中寻找, 进行全局替换。

【注意】修改包名之后,记住需要将存放MainActivity.kt类的文件夹名也一并修改,否则将会找不到类。

  • 修改应用ID。修改android/app/build.gradle文件中的applicationId

  • 修改应用名。修改android/app/src/main/res/values/strings.xml文件中的app_name

IOS目录修改

ios修改相对简单,直接使用XCode打开ios目录进行修改即可。如下图所示:

flutter_template's People

Contributors

xuexiangjys avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.