Skip to content

Instantly share code, notes, and snippets.

View laohanme's full-sized avatar
🍊
Available

LaoHan laohanme

🍊
Available
View GitHub Profile
@steven-tey
steven-tey / youtube-channel.tsx
Last active April 18, 2024 11:14
YoutubeChannel RSC
import { BlurImage, YouTube } from "@dub/ui";
import { nFormatter } from "@dub/utils";
import { Eye, UserCheck, Video } from "lucide-react";
import { Suspense } from "react";
export function YoutubeChannel({ id }: { id: string }) {
return (
<Suspense fallback={<div className="not-prose grid gap-4"></div>}>
<YoutubeChannelRSC id={id} />
</Suspense>
@V8tr
V8tr / AutoLayoutDSL.swift
Last active October 31, 2023 17:42
Auto Layout DSL
import UIKit
/// Represents a single `NSLayoutConstraint`
enum LayoutAnchor {
case constant(attribute: NSLayoutConstraint.Attribute,
relation: NSLayoutConstraint.Relation,
constant: CGFloat)
case relative(attribute: NSLayoutConstraint.Attribute,
relation: NSLayoutConstraint.Relation,
@ethanhuang13
ethanhuang13 / xcode-beta-slink.sh
Last active February 3, 2023 20:21
Symbolic link from Xcode.app to Xcode-beta.app (Xcode 11.2)
@zulhfreelancer
zulhfreelancer / malaysia_postcode_list.json
Last active June 8, 2020 12:11
Malaysia Postcode List By State (JSON)
{
"prepared_by": "Zulhilmi Zainudin",
"last_update": "21 June 2016",
"data": [
{
"state": "Selangor",
"codes": [
"40000",
"40100",
@zulhfreelancer
zulhfreelancer / poslaju_api_v2.md
Last active April 23, 2021 17:25
Poslaju API V2 Endpoint & Result Example

Disclaimer

I'm not working for Poslaju and I don't provide support for this.


Endpoint:

http://api.pos.com.my/v2TrackNTraceWebApi/api/Details/[TRACKING_NUMBER]?callback=result&sKey=7oHHMvxM0&_=1447773442872

@keeguon
keeguon / countries.json
Created April 5, 2012 11:11
A list of countries in JSON
[
{name: 'Afghanistan', code: 'AF'},
{name: 'Åland Islands', code: 'AX'},
{name: 'Albania', code: 'AL'},
{name: 'Algeria', code: 'DZ'},
{name: 'American Samoa', code: 'AS'},
{name: 'AndorrA', code: 'AD'},
{name: 'Angola', code: 'AO'},
{name: 'Anguilla', code: 'AI'},
{name: 'Antarctica', code: 'AQ'},