SwiftUI dev
1.2K subscribers
87 photos
38 videos
1 file
75 links
Mobile development, SwiftUI, Compose, feel free to reach me: @lexkraev

По вопросам рекламы: @lexkraev

Статистика/цены: @lexkraev_ads
Download Telegram
Сделал package для добавления swipe-меню на любое View для iOS 13.0 (Apple-овский аналог доступен только для List, начиная с iOS 15.0)

Made the package for creating swipe actions for any SwiftUI View, similar to Apple's swipeActions(edge:allowsFullSwipe:content:) that available from iOS 15 and only in List 🤷🏼‍♂️. You can use SwipeActions in project targeting iOS 13 with any view (for ex. Text in VStack)

#swiftpm #getsources
This media is not supported in your browser
VIEW IN TELEGRAM
Сделал package с примером реализации показа всплывающих окон/alert-ов/popover-ов/sheet-ов из любого места в приложении на SwiftUI.
Перед просмотром советую освежить в памяти про EnvironmentValues и прочитать эту статью.

Made a package with an example of the implementation of showing pop-up windows / alerts / popovers / sheets from anywhere in the application on SwiftUI.
Before watching, I advise you to refresh in memory for EnvironmentValues and read this article.

#swiftpm #getsources
SwiftUI dev
Навигация Один из блоков вопросов на iOS - собеседовании - архитектура приложений. При этом почти в любой архитектуре вопросы навигации всегда находятся сбоку от обсуждения. Более того, для навигации разрабатывают свои паттерны. Одними из таких являются координатор…
Navigation

Hey guys! I’ve created test project with sample of new navigation API back ported in older SwiftUI versions.

One of the main question at every iOS-interview is app architecture. At the same time routing in the app almost always is the side theme of discussion. Moreover there are different approaches in the navigation in general and all of them have their own patterns such as navigator or coordinator.

Starting from SwiftUI 1.0 in almost every WWDC Apple talks about working with MVVM as if forgetting about routing. Yes, we were introduced to NavigationView, NavigationLink. But the feeling that Apple again has presented intermediate solution does not leave us. Some developers started to create their own wrappers over this API for convenience. Finally in iOS 16 Apple introduced the long-awaited new navigation API.

Instead of NavigationView (starting with iOS 16 it has been deprecated) we have to use NavigationStack. Now the navigationDestination modifier defines a view to display.

Frankly speaking many teams are still using UIKit routing in SwiftUI projects. Even those who tried to understand NavigationView, gave up and went back to UIKit. With the release of the new navigation API, this approach is a wrong turn. Apart from that the new API requires a minimum deployments as iOS 16.0. So what to do? Use a backport! Try my sample! You may create your own test project to try to work with this package using it.

#swiftpm #howto #getsources
This media is not supported in your browser
VIEW IN TELEGRAM
Сделал package для добавления pull-to-refresh на любое View для iOS 14.0 (Apple-овский аналог доступен только для List, начиная с iOS 15.0)

Made the package for marking any SwiftUI View as refreshable, similar to Apple's refreshable(action:) that available from iOS 15 and only in List 🤷🏼‍♂️.

#swiftpm #groovy #getsources

@swiftui_dev
SwiftUI dev
Сделал package для добавления swipe-меню на любое View для iOS 13.0 (Apple-овский аналог доступен только для List, начиная с iOS 15.0) Made the package for creating swipe actions for any SwiftUI View, similar to Apple's swipeActions(edge:allowsFullSwipe:content:)…
This media is not supported in your browser
VIEW IN TELEGRAM
✌🏻 Обновил package SwipeActions. Напомню, либа добавляет swipe-меню для любых view. У Apple аналог только для List и только с iOS 15.

Краткий мануал здесь.

✌🏻 I've just released SwipeActions new version. It allows you to add swiped menu to any SwiftUI view, quite similar to Apple’s one that available from iOS 15 and only for Lists.

Release notes are here.

Quick start is here.

#swiftpm #tasty #groovy #getsources

@swiftui_dev
This media is not supported in your browser
VIEW IN TELEGRAM
🤸🏻‍♂️🤾🏻‍♂️ Сделал package Animatable. Либа позволяет добавить кастомные реакции на нажатия кнопок.

Краткий мануал здесь.

Спасибо за репосты 🤝

🤸🏻‍♂️🤾🏻‍♂️ Yet another package Animatable with animation modifiers for buttons . It allows you to add custom reaction on button tapping.

Quick start is here.

Thx for sharing 🤝

#swiftpm #tasty #groovy #getsources
⚖️ Хорошая либа FluentUI от Microsoft как пример того, как можно хорошо структурировать дизайн-систему

👷‍♂️ Nice package Microsoft's Fluent UI as example how you can organize your design system

#swiftpm #howto #getsources #groovy
This media is not supported in your browser
VIEW IN TELEGRAM
🎆 Обновил либу Animatable. Добавил анимации для скелетонов (и для других view). Мелочь, но пользователям будет интерактивнее ☺️

Краткий мануал здесь 📚

🎆 Just updated Animatable. Add shimmers and blinking effect for skeletons or other views. Hope you like it 👍🏻

Quick start is here 👨‍🏫

#swiftpm #tasty #groovy #getsources

@swiftui_dev
This media is not supported in your browser
VIEW IN TELEGRAM
💳 Все больше сервисов на рынке внедряют в свои приложения СБП (сервис быстрых платежей).

Готовое SDK для работы можно найти здесь.

💳 Swift package for the service SBP, more details about SBP you can find here.

#swiftpm #tasty #getsources

@swiftui_dev
🧭 Быстрая навигация на канале

#readthis - ссылки на статьи, книги и др
#watchthis - ссылки на видео
#howto - воркшопы, обучающие статьи и т п
#getsources - ссылки на проекты с открытым исходным кодом (включая #swiftpm модули)
#trytodo - челенджи, иногда простые, иногда не очень
#groovy - посты с наибольшим количеством шарингов и реакций
#tasty - “посмотри, чтоб вдохновиться”, здесь будут анимации, концепты и т п
🧭 Quick navigation

#readthis - recommended articles, books, etc
#watchthis - recommended videos, clips, etc
#howto - tutorials, rtfm
#getsources - where the hell are sources? open-source repositories (including my own swift packages #swiftpm), projects
#trytodo - “try to do” challenges, sometimes not easy
#groovy - trending high-rated posts based on statistics (private or public sharing and positive reactions)
#tasty - cool creative features (animations, concepts, etc), might be useful for inspiring developers, designers or PMs
Media is too big
VIEW IN TELEGRAM
📱 ↕️ Bottom sheet – это неотъемлемый элемент современных мобильных приложений, который получил широкое распространение благодаря своей универсальности и удобству. Они позволяют эффективно организовать взаимодействие пользователя с интерфейсом, предоставляя доступ к дополнительной информации или действиям, не покидая текущего экрана. Bottom sheet отлично подходят для контекстных меню, форм и быстрых настроек, оставаясь при этом интуитивно понятными благодаря своей привычной для пользователей механике. Их способность адаптироваться к разным сценариям делает их полезными для создания удобных и красивых приложений. Таким образом, это не только модный элемент, а важный инструмент, которая помогает улучшить навигацию, повысить удобство использования приложения для его пользователями.

Но, как это обычно бывает, в SwiftUI bottom sheet появились только в iOS 16, а многие полезные модификаторы для их настройки и вовсе позже - с iOS 16.4. Это создает определенные сложности на проектах, где необходимо поддерживать более ранние версии iOS. В таких случаях, предлагаю вам использовать мой package. Это самостоятельное решение представляет собой реализацию, вдохновленную подходом бэкпорта.

Основная идея состоит в следующем:
• Если на устройстве пользователя установлена iOS версии 16.4 или новее, будет использована нативная реализация bottom sheet.
• Если версия iOS ниже 16.4, то автоматически активируется кастомная реализация.

При необходимости такое поведение можно отключить, оставив исключительно кастомную реализацию.

Краткий мануал здесь.

📋 🔽 Bottom sheets have become a standard in modern mobile apps, thanks to their killer versatility and seamless UX. They let you keep the user on the same screen while offering up extra info or actions on demand. Bottom sheets are well-suited for context menus, forms, and quick settings, remaining intuitive due to the familiar interaction pattern they employ. Their adaptability to different scenarios makes them highly useful for creating aesthetically pleasing and user-friendly applications. Thus, bottom sheets aren’t just a trendy widget – they’re a core tool that boosts navigation flow and levels up overall app usability.

However, as is often the case, SwiftUI introduced native bottom sheets only in iOS 16, and many useful modifiers for their configuration were added even later, starting in iOS 16.4. That’s a headache if your project has to support older iOS versions. Enter my swift package: it’s a custom solution inspired by the whole backport approach.

The core idea is as follows:
• If the user's device is running iOS 16.4 or later, the native bottom sheet implementation will be used.
• If the iOS version is earlier than 16.4, the custom implementation will automatically be activated.

You can disable this behavior if desired, opting to use only the custom implementation.

Quick guide is here.

#swiftpm #tasty #groovy #getsources

@swiftui_dev
Media is too big
VIEW IN TELEGRAM
🏷️ Ещё некоторое время назад разработка новых фичей на Android требовала бОльших затрат времени, нежели на iOS. Все изменилось с приходом Jetpack Compose, где множество компонентов доступно «из коробки» c высокой степенью кастомизации.

Одним из таких компонентов Compose стали FlowRow и FlowColumn — лэйауты, которые позволяют автоматически переносить элементы на следующую строку или колонку при нехватке пространства. Это особенно полезно при отображении тегов, фильтров, коллекций с динамическим числом элементов и других интерфейсных паттернов.

А что в SwiftUI? С выходом iOS 16 Apple представила механизм кастомных Layout'ов, который существенно расширил возможности по созданию сложных лэйаутов. Однако проекты, ориентированные на iOS 13, по-прежнему нуждаются в решениях, обеспечивающих аналогичный функционал.

Моя библиотека Flow закрывает этот пробел, предоставляя разработчикам мощный и гибкий инструмент для построения адаптивных интерфейсов в SwiftUI на iOS 13 и выше. Компоненты поддерживает передачу произвольного содержимого в замыкании через ViewBuilder. Это означает, что внутрь лэйаута можно передать абсолютно любые view, включая Text, Button, Label, кастомные компоненты, а также сложные композиции вью, комбинирующие различные элементы.

Если вы ищете решение, аналогичное FlowRow в Compose, библиотека Flow станет отличным выбором для вашего проекта.

Краткий мануал здесь

🏷️ Not so long ago, developing new features on Android used to take more time compared to iOS. Everything changed with the arrival of Jetpack Compose, which provides many UI components out of the box along with a high degree of customization.

Such component in Compose are FlowRow and FlowColumn — layouts that automatically wrap elements to the next row or column when there isn’t enough space. This is especially useful for displaying tags, filters, collections with a dynamic number of items, and other interface patterns.

But what about SwiftUI? With the release of iOS 16, Apple introduced the custom Layout API, which significantly expanded the capabilities for building advanced layouts. However, many projects targeting iOS 13 and above still require alternative solutions to achieve similar functionality.

My package Flow fills this gap by providing developers with a powerful and flexible tool for building adaptive layouts in SwiftUI on iOS 13+. The component supports passing arbitrary content into the closure via ViewBuilder. This means you can embed any SwiftUI views inside the layout — including Text, Button, Label, custom components, or even complex view compositions combining multiple elements.

If you're looking for a solution similar to FlowRow in Compose, the Flow package is a great choice for your SwiftUI project.

Quick guide is here

#swiftpm #tasty #groovy #getsources

@swiftui_dev