Skip to content

Instantly share code, notes, and snippets.

import SwiftUI
import UIKit
import TOCropViewController
struct Page: Identifiable {
var id: Int
var image: Image
}
struct ContentView: View {
@karm435
karm435 / LazyVGrid.swift
Created March 22, 2022 10:02
LazyVGrid Sample
import SwiftUI
struct CustomText: View {
private let index: Int
init(index: Int) {
print("init CustomText \(index)")
self.index = index
}
var body: some View {
Text("This is custom text view \(index)")
@karm435
karm435 / LazyHGrid.Swift
Created March 22, 2022 10:01
LazyHGrid sample
import SwiftUI
struct CustomText: View {
private let index: Int
init(index: Int) {
print("init CustomText \(index)")
self.index = index
}
var body: some View {
Text("This is custom text view \(index)")
@karm435
karm435 / LazyVStack.Swift
Created March 22, 2022 09:58
LazyVStack sample code
import SwiftUI
struct CustomText: View {
private let index: Int
init(index: Int) {
print("init CustomText \(index)")
self.index = index
}
var body: some View {
Text("This is custom text view")
@karm435
karm435 / ContentView.Swift
Created March 22, 2022 09:56
HStack example
import SwiftUI
struct CustomText: View {
private let index: Int
init(index: Int) {
print("init CustomText \(index)")
self.index = index
}
var body: some View {
Text("This is custom text view")
@karm435
karm435 / ios-deploy.yaml
Created November 27, 2020 03:29
ios deployment
parameters:
- name: appIdentifier
type: string
- name: artifactName
type: string
- name: serverEndpoint
type: string
steps:
- download: current
@karm435
karm435 / ios-build.yaml
Created November 27, 2020 03:28
ios build
- name: provisioningProfileFilePath
displayName: "The file path to the .mobileprovision file"
type: string
- name: provisioningProfileName
displayName: "The name of the .mobileprovision file"
type: string
- name: certificateSecureFileName
displayName: "Name of the .p12 file"
type: string
- name: certificatePassword
@karm435
karm435 / android-deployment
Last active November 27, 2020 03:22
android deployment
parameters:
- name: appCenterServiceConnection
displayName: 'Name of the service connection with App Center'
- name: appSlug
displayName: 'Path to application in AppCenter'
- name: appFile
displayName: 'Path of the apk to deploy'
- name: releaseNotes
displayName: 'Release notes'
- name: distributionGroupId
@karm435
karm435 / android-build
Created November 27, 2020 03:19
Android build
# Starter pipeline
parameters:
- name: keystoreFileName
displayName: "The keystore file name for signing the apk"
type: string
- name: keystorePassword
displayName: "Password for the keystore"
type: string
- name: keyAlias
@karm435
karm435 / ionic-build.yml
Created November 27, 2020 03:15
Ionic build steps
parameters:
- name: environment
displayName: "Ionic Build environment"
steps:
- task: NodeTool@0
inputs:
versionSpec: '12.x'
displayName: 'Install Node.js'