Type Safely

Type Safely

Share this post

Type Safely
Type Safely
Create a Custom Stepper From Scratch
Copy link
Facebook
Email
Notes
More

Create a Custom Stepper From Scratch

Daily Coding Tip 254

Type Safely's avatar
Type Safely
Feb 24, 2023
∙ Paid

Share this post

Type Safely
Type Safely
Create a Custom Stepper From Scratch
Copy link
Facebook
Email
Notes
More
Share
black portable speaker
Photo by Przemyslaw Marczynski on Unsplash

I’m going to replicate Apple’s system Stepper control in several ways.

First the initialiser for Stepper that I’m going to be imitating takes a numeric type that conforms to the Strideable protocol. This allows for an individual movement in a type to be specified by a type called a Stride, which is often the sam…

Keep reading with a 7-day free trial

Subscribe to Type Safely to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2025 Type Safely
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share

Copy link
Facebook
Email
Notes
More