Reorder Lists & Grids in SwiftUI and Save with SwiftData

SwiftUI's onMove makes reordering lists easy. But that order disappears when the app relaunches — unless you save it.

What this video covers:

  • Adding drag-to-reorder to List and LazyVGrid
  • Using onMove and onInsert modifiers
  • Capturing the new order after drag
  • Saving order changes to SwiftData (persistent storage)
  • Restoring saved order on app launch
  • Handling sections and complex data

Real example: A to-do list, playlist, or dashboard where users can rearrange items and expect their order to stay.

In partnership with
Fastlane alternative – CLI tools

Are you tired of Ruby and Fastlane installation issues? There's got to be a better way! Discover Codemagic open source CLI tools. It is not a drop-in replacement for all of what Fastlane does (screenshots for example), but we use it at Codemagic to build and publish iOS and Android apps, also versioning and device provisioning.

View on GitHub
© 2026 Mobile Signal. All rights reserved.
Made by
Stan
linkedin