Skip to content

Instantly share code, notes, and snippets.

View jrsaruo's full-sized avatar

Yusaku Nishi jrsaruo

View GitHub Profile
@jrsaruo
jrsaruo / HorizontalInlinePicker.swift
Last active February 24, 2025 06:31
Horizontal Inline Picker by SwiftUI
import SwiftUI
// https://x.com/jrsaruo_tech/status/1893585977760743750
@available(iOS 18, *)
struct HorizontalInlinePicker<SelectionValue, Content>: View where SelectionValue: Hashable, Content: View {
@Binding var selection: SelectionValue
@State private var centerValue: SelectionValue?
@jrsaruo
jrsaruo / LoveInjection.swift
Created September 23, 2023 14:35
ドドスコード.swift
import Foundation
// https://x.com/jrsaruo_tech/status/1554444893208334336
enum DodoOrSuko: String, CaseIterable {
case ドド, スコ
}
enum DodoSukoState: Equatable {
case ready