Skip to content

Instantly share code, notes, and snippets.

@sk-chanch
sk-chanch / LongPressGestureRecognizerExtension.swift
Last active Mar 31, 2021
RxSwift ObservableType UILongPressGestureRecognizer LongPressGesture inspired from https://gist.github.com/saoudrizwan/43ba7adad04ae28bbf8bd96431f7749b.
View LongPressGestureRecognizerExtension.swift
//
// LongPressGestureRecognizerExtension.swift
// AppStarterKit
//
// Created by Chanchana Koedtho on 31/3/2564 BE.
//
import Foundation
import RxSwift
@sk-chanch
sk-chanch / CustomRatingView.swift
Last active Oct 27, 2020
Simple Star Rating for swift
View CustomRatingView.swift
//
// CustomRatingView.swift
// AppStarterKit
//
// Created by MAC-KHUAD on 26/10/2563 BE.
// Copyright © 2563 megazy. All rights reserved.
//
import UIKit
import RxSwift
@sk-chanch
sk-chanch / randomLocations.swift
Created Jun 4, 2020 — forked from inorganik/randomLocations.swift
Return a cluster of random locations around a given location
View randomLocations.swift
import Foundation
import CoreLocation
struct randomLocations {
// create random locations (lat and long coordinates) around user's location
func getMockLocationsFor(location: CLLocation, itemCount: Int) -> [CLLocation] {
func getBase(number: Double) -> Double {
return round(number * 1000)/1000
View ioslocaleidentifiers.csv
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
mr Marathi
bs Bosnian
ee_TG Ewe (Togo)
ms Malay
kam_KE Kamba (Kenya)
mt Maltese
ha Hausa
es_HN Spanish (Honduras)
ml_IN Malayalam (India)
ro_MD Romanian (Moldova)