SwiftUI Search Bar - Searchable

Опубликовано: 30 Май 2023
на канале: Sean Allen
19,683
592

Go to https://squarespace.com/seanallen to save 10% off your first purchase of a website or domain using code SEANALLEN.

A search bar in SwiftUI can be created in a few simple steps. This search bar allows you to filter an existing list of data based on your search term using SwiftUI's searchable modifier. The search bar is placed in the NavigationStack (or NavigationView for older versions of iOS) and a user types in a search term. The search term is compared with the list of data and a filtered list is shown displaying the search results.

This tutorial was created using Xcode 14 and iOS 16.

My iOS Dev Courses:
https://seanallen.teachable.com/

Twitter:
Sean Allen -   / seanallen_dev  

Hired.com:
https://hired.com/x/1n01g

Book and learning recommendations that help out the channel if you decide to purchase (Affiliate Links):

Paul Hudson's Hacking With Swift:
https://gumroad.com/a/762098803

Donny Wals - Combine:
https://gumroad.com/a/909014131

Mark Moeyken’s SwiftUI Books:
www.bigmountainstudio.com/swiftui-views-book/fzc51

Objc.io Books (Thinking in SwiftUI & Advanced Swift):
https://gumroad.com/a/656585843

#swift #softwaredeveloper #iosdeveloper

Timestamps:
0:00 - What is Searchable
0:58 - NavigationStack Requirement
1:39 - Search Term
1:54 - Searchable Modifier
3:00 - Code to Filter Search Results
5:00 - Final Code


Смотрите видео SwiftUI Search Bar - Searchable онлайн, длительностью часов минут секунд в хорошем качестве, которое загружено на канал Sean Allen 30 Май 2023. Делитесь ссылкой на видео в социальных сетях, чтобы ваши подписчики и друзья так же посмотрели это видео. Данный видеоклип посмотрели 19,683 раз и оно понравилось 592 посетителям.