![]() ![]() Images of your icon should be exported into a directory specified in exportURL variable. Make sure you have selected the build scheme connected with your executable target ( export in this example). 5️⃣ Run the executable from Xcode to export your icon images Feel free to adjust the exportURL variable to your needs. In above example the images will be exported to MyAppIcon directory on current user's desktop. Check out IconConfig.swift for possible options. Add swiftui-app-icon-creator package as a dependency. You can adjust the configs variable to specify which types of the icon you want to export. Library that will contain your icon source code Executable that you will use to export icon images. Struct MyAppIconView_Preivews: PreviewProvider Just create a new SwiftUI view in the library target: import SwiftUIģ️⃣ Use IconPreviews to live-preview your icon in XcodeĪdd this code to the file which contains your icon view: import AppIconCreator 2) Also delete the 'Brand Assets' folder if you created one just to be safe. target(name: "Export", dependencies: )Ģ️⃣ Create icon view in the library taget, using SwiftUI So here are the steps you need to take to add an App Icon: 1) If you've clicked on the the arrow next to 'App Icons Source' then click on your 'Images.xcassets' file that it created and delete the 'BrandAsset' folder. product(name: "AppIconCreator", package: "swiftui-app-icon-creator") ![]() target(name: "MyAppIcon", dependencies: [ Your Package.swift should like this: // swift-tools-version:5.3 Executable that you will use to export icon imagesĪdd swiftui-app-icon-creator package as a dependency.Activate the instant download option to directly download all. The image is uploaded and the icons are generated automatically. Just drag and drop the original image on the upload area or upload it manually. Library that will contain your icon source code A simple service to resize your app icon to all needed resolutions with rocket speed.1️⃣ Create a new Swift Packageĭefine two products in your Package.swift: ![]() TL DR: check out example project in this repository. Create iOS and macOS application icon in Xcode with SwiftUI ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |