Skip to content

Instantly share code, notes, and snippets.

@mrackwitz
mrackwitz / AutoHeightLabelView.swift
Created October 27, 2020 19:53
A UILabel-based SwiftUI view which auto-expands to the width of the container, and only expand to render the full height of the label.
struct AutoHeightLabelView: View {
var attributedString: NSAttributedString
var body: some View {
HorizontalGeometryReader { width in
UILabelView(
attributedString: attributedString,
preferredMaxLayoutWidth: width
)
}
@mbinna
mbinna / podforceupdate.sh
Created December 4, 2012 09:43
Clear CocoaPods cache, re-download and re-install all pods
#!/usr/bin/env bash
rm -rf "${HOME}/Library/Caches/CocoaPods"
rm -rf "`pwd`/Pods/"
pod update
@unnamedd
unnamedd / .gitconfig
Last active March 14, 2024 13:19
Personal Git Configurations / Git Config
[core]
excludesfile = /Users/unnamedd/.gitignore
editor = code
autocrlf = false
pager = delta
[user]
name = Thiago Holanda
email = unnamedd@gmail.com
signingkey = CD1B6C70016B3BD91C38BC49F94B6756E6B6D57A
[alias]
<!doctype html>
<!-- http://taylor.fausak.me/2015/01/27/ios-8-web-apps/ -->
<html>
<head>
<title>iOS 8 web app</title>
<!-- CONFIGURATION -->