Skip to content

Instantly share code, notes, and snippets.

View Shahroz16's full-sized avatar

Shahroz Khan Shahroz16

View GitHub Profile
@okmanideep
okmanideep / EventQueue.kt
Last active January 5, 2023 15:27
Event abstraction for Jetpack Compose
import androidx.compose.runtime.*
import kotlinx.coroutines.CoroutineScope
@Stable
internal class Event<T>(val value: T)
class MutableEventQueue<T>
internal constructor(): EventQueue<T>() {
private val events = mutableListOf<Event<T>>()
private val nextEventAsState = mutableStateOf<Event<T>?>(null)
@ibraheem4
ibraheem4 / postgres-brew.md
Last active April 25, 2024 08:55 — forked from sgnl/postgres-brew.md
Installing Postgres via Brew (OSX)

Installing Postgres via Brew

Pre-Reqs

Brew Package Manager

In your command-line run the following commands:

  1. brew doctor
  2. brew update
@anggadarkprince
anggadarkprince / AppHelper.java
Last active May 2, 2023 22:39
Upload file with Multipart Request Volley Android
import android.graphics.Bitmap;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import java.io.ByteArrayOutputStream;
/**
* Sketch Project Studio
* Created by Angga on 12/04/2016 14.27.
*/
public class AppHelper {
@chrisbanes
chrisbanes / FloatLabelLayout.java
Last active March 15, 2024 06:39
FloatLabelLayout
/*
* Copyright 2014 Chris Banes
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software