4
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

[Flutter] 5分以内でアプリのアイコンの実装をしよう

Last updated at Posted at 2023-04-26

 
 
この記事を開いてから、5分以内にアプリのアイコンを実装してみましょう。
この記事の趣旨としては簡単に、手早くアイコンを実装するやり方を記載しているので、詳細な設定は調べてみてください。
 
 

1、画像を探す

ここは探そうとしたり、作ったりすると無限に時間がかかるので、時間は含めないようにします。僕は商標OKな画像を探して、Figmaで編集をしています。だいたい、20分〜30分ぐらいで完成しきります。

2、アイコンをファイルの中に入れよう

assets
 - images
   - icon
     - icon.png

3、pubspec.yamlに追加しよう

pubspec.yaml
dev_dependencies:
  flutter_test:
    sdk: flutter
  flutter_lints: ^2.0.0
  #追加する
  flutter_launcher_icons: ^0.11.0

#追加する
flutter_icons:
  android: true
  ios: true
  remove_alpha_ios: true
  image_path: "assets/icon/icon.png"
  min_sdk_android: 21
  adaptive_icon_background: '#FFF422'
  adaptive_icon_foreground: "assets/icon/icon.png"

4、コマンドで生成する

flutter pub run flutter_launcher_icons

これで終わり!!!

 

以上です。僕の場合はアプリを47個出しているので、提出周りやアイコン作成はRTAみたいな感じで素早くやることが多いです。ぜひ試してください。アイコンのズレなどは公式のPackageを探して修正するともっと良くなります!

4
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?