Skip to content

Instantly share code, notes, and snippets.

View IuriiIaremenko's full-sized avatar
✌️

iurii iaremenko IuriiIaremenko

✌️
View GitHub Profile
@vibrazy
vibrazy / Toggle.swift
Created May 10, 2021 10:56
Toggled - Simpler way to deal with hardcoded ViewModifers values in SwiftUI
struct ToggledExampleView_Previews: PreviewProvider {
static var previews: some View {
DebuggingToggledExampleView()
}
}
// MARK: - Toggled Source
protocol ToggleInterface {
associatedtype ValueType
@Noluk1991
Noluk1991 / Устройство многопоточности в iOS (Podlodka iOS Crew. Season 3)
Last active June 18, 2024 10:39
Дополнительные материалы к докладу
// Разное интересное по многопоточности:
// Featured-секция, для любителей архивной документации от Apple:
1. https://developer.apple.com/library/archive/technotes/tn/tn2028.html#//apple_ref/doc/uid/DTS10003065 - про внутренности потоков в MAC OS X в сравнении с MAC OS 9
2. https://developer.apple.com/library/archive/documentation/Darwin/Conceptual/KernelProgramming/About/About.html - Kernel Programming guide, вы же понимаете, что там будет, да :D
// Для любителей WWDC:
1. https://developer.apple.com/videos/play/wwdc2015/718/ - GCD раз.
@katleta3000
katleta3000 / Mobius 2019
Last active February 29, 2024 22:08
Список материалу к докладу "Работаем с сетью эффективно" Ртищев Евгения для Mobius 2019 22-23 мая
1. Очень крутая книжка по сетям (стек OSI) – Charles Severance “Introduction to Network: How the Internet works”
2. URLCache – https://nshipster.com/nsurlcache/
3. Ресёрч HTTP-кеширования с использованием URLCache https://qnoid.com/2016/04/10/A-primer-in-HTTP-caching-and-its-native-support-by-iOS.html
4. Анализ доступности сети:
* SimplePing – https://developer.apple.com/library/archive/samplecode/SimplePing/Introduction/Intro.html
* https://github.com/dustturtle/RealReachability
* https://github.com/ankitthakur/SwiftPing
* https://github.com/lmirosevic/GBPing
* https://github.com/rwbutler/Connectivity
* Баг с 2009 года – https://lists.apple.com/archives/macnetworkprog/2009/May/msg00056.html
import Foundation
protocol Currency { static var sign: String { get } }
enum GBP: Currency { static let sign = "£" }
enum EUR: Currency { static let sign = "€" }
enum USD: Currency { static let sign = "$" }
protocol _Money {
associatedtype C: Currency
var amount: NSDecimalNumber { get }