Skip to content

Instantly share code, notes, and snippets.

View kazimunshimun's full-sized avatar

Kazi Munshimun Nabi kazimunshimun

  • CHECK24 Finanzservice GmbH
  • Munich, Germany
View GitHub Profile
@stammy
stammy / LiquidBlobs.swift
Last active July 24, 2024 14:49
Liquid Blob effect with SwiftUI
//
// ContentView.swift
// LiquidCircles
//
// Created by Paul Stamatiou on 10/10/22.
//
import SwiftUI
struct ContentView: View {
@pallavtrivedi03
pallavtrivedi03 / iOSCodeReviewChecklist.txt
Created September 18, 2021 16:50
A checklist for iOS Code Review.
iOS Code Review Checklist
Avoid Type Inference
Prefer using Higher Order Functions
Write DRY code (Don’t Repeat Yourself)
Make sure that there are no force unwraps
Make sure that there are no retain cycles
Check if any deprecated API is being used
Check if any hardcoded checks (generally strings) can be changed to enum.
Prefer enum, switch over if else.
@mecid
mecid / Calendar.swift
Last active August 23, 2024 16:39
SwiftUI Calendar view using LazyVGrid
import SwiftUI
extension Calendar {
func generateDates(
inside interval: DateInterval,
matching components: DateComponents
) -> [Date] {
var dates: [Date] = []
dates.append(interval.start)
// Advanced SwiftUI Transitions
// https://swiftui-lab.com
// https://swiftui-lab.com/advanced-transitions
import SwiftUI
struct CrossEffectDemo: View {
let animationDuration: Double = 2
let images = ["photo1", "photo2", "photo3", "photo4"]
@State private var idx = 0
//------------------------------------------------------------------------
// The SwiftUI Lab: Advanced SwiftUI Animations
// https://swiftui-lab.com/swiftui-animations-part1 (Animating Paths)
// https://swiftui-lab.com/swiftui-animations-part2 (GeometryEffect)
// https://swiftui-lab.com/swiftui-animations-part3 (AnimatableModifier)
//------------------------------------------------------------------------
import SwiftUI
struct ContentView: View {
@mecid
mecid / Networking.swift
Last active June 19, 2023 16:35
Networking layer in Swift
import Foundation
import Combine
enum HTTPMethod: String {
case put = "PUT"
case post = "POST"
case get = "GET"
case delete = "DELETE"
case head = "HEAD"
}