Skip to content

Instantly share code, notes, and snippets.

View akbashev's full-sized avatar
🐢
Slowly learning stuff

Jaleel Akbashev akbashev

🐢
Slowly learning stuff
View GitHub Profile
@akbashev
akbashev / displaysizes.txt
Last active March 1, 2021 08:52 — forked from marcedwards/displaysizes.txt
iPhone, iPad, and Apple Watch display sizes
### Points and display type
PPI is points per inch below, not pixels per inch. Not all models are listed, just the first model with a new display size. Diamond, RGB Stripe and Pentile RGB refer to the subpixel patterns.
iPhone 1 = 320×480 at 163ppi sRGB IPS LCD RGB Stripe
iPhone 4 = 320×480 at 163ppi sRGB IPS LCD RGB Stripe
iPhone 5 = 320×568 at 163ppi sRGB IPS LCD RGB Stripe
iPhone 6 = 375×667 at 163ppi sRGB IPS LCD RGB Stripe
iPhone 6 Plus = 414×736 at 153.5ppi sRGB IPS LCD RGB Stripe
iPhone 7 = 375×667 at 163ppi P3 IPS LCD RGB Stripe
@akbashev
akbashev / Promised.swift
Last active August 29, 2022 18:50 — forked from rjchatfield/Promised.swift
Promised values in Swift Concurrency
/// Wrapper around a lazily resolved using checked continuation.
///
/// Usage:
///
/// ```
/// let promiseA = Promised<String>()
/// async let a1 = promiseA.value
/// promiseA.resolve(with: "AAA")
/// let a2 = try await promiseA.value
/// print(try await a1, a2)