Skip to content

Instantly share code, notes, and snippets.

View WrathChaos's full-sized avatar
❤️‍🔥
Working Hard

FreakyCoder WrathChaos

❤️‍🔥
Working Hard
View GitHub Profile
@mrousavy
mrousavy / react-navigation-shared-element-v5-guide.md
Last active June 12, 2022 12:56
React Navigation Shared Element v5 Guide

How to use React Navigation Shared Element v5

Install

Run:

npm i react-navigation-shared-element@next react-native-shared-element
npm i @react-navigation/native@^5.0.9 @react-navigation/stack@^5.1.1
@helenaford
helenaford / 1: App.js
Last active March 20, 2024 09:16
useNotificationService
import { useNotificationService } from './hooks';
function App() {
useNotificationService();
...
}
@dvf
dvf / change-codec.md
Last active May 21, 2024 16:48
Enable High Quality mode on your headphones (Updated for macOS Catalina)

If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.

Find out what codec you're using

  1. Play a song on your headphones
  2. Option (⌥) click the Bluetooth button at the top of your screen Inspect the Bluetooth Coded
  3. If you're using AAC or aptX, you can stop here—those are the highest quality codecs.

Change your codec to AAC or aptX

@WrathChaos
WrathChaos / git-alias.md
Last active May 13, 2021 15:39
MacOS .zshrc Aliases

Git Aliases

alias status="artii 'Status' | nyan && git status | nyan"
alias add="git add . | artii "Staged" | nyan"
alias glocal="git checkout local | artii 'Local Branch' | nyan"
alias dev="git checkout dev | artii 'Dev Branch' | nyan"
alias master="git checkout master | artii 'Master Branch' | nyan"
alias log="artii 'Logs' | nyan  && git log | nyan"
alias branch="artii 'Branches' | nyan && git branch | nyan"
@dmamills
dmamills / example.js
Created August 22, 2017 13:25
Open/Close react-native animation example
import React, { Component } from "react";
import { AppRegistry, StyleSheet, Text, Dimensions, View, Animated, TouchableWithoutFeedback } from "react-native";
export default class animations extends Component {
state = {
played: false,
text: 'Welcome!',
animation: new Animated.Value(50),
a2: new Animated.Value(50),
at: new Animated.Value(0),
@codediodeio
codediodeio / geo-json.ts
Last active November 9, 2021 12:54
A Typescript interface for GeoJSON objects based on rfc7946
export interface IGeometry {
type: string;
coordinates: number[];
}
export interface IGeoJson {
type: string;
geometry: IGeometry;
bbox?: number[];
properties?: any;
@mike-casas
mike-casas / install-nvm-zsh.txt
Last active March 14, 2024 20:40
install nvm on mac with zsh shell
After install zsh
- brew update
- brew install nvm
- mkdir ~/.nvm
after in your ~/.zshrc or in .bash_profile if your use bash shell:
export NVM_DIR=~/.nvm
source $(brew --prefix nvm)/nvm.sh
@maciekish
maciekish / resetXcode.sh
Created August 10, 2016 10:13
Reset Xcode. Clean, clear module cache, Derived Data and Xcode Caches. You can thank me later.
#!/bin/bash
killall Xcode
xcrun -k
xcodebuild -alltargets clean
rm -rf "$(getconf DARWIN_USER_CACHE_DIR)/org.llvm.clang/ModuleCache"
rm -rf "$(getconf DARWIN_USER_CACHE_DIR)/org.llvm.clang.$(whoami)/ModuleCache"
rm -rf ~/Library/Developer/Xcode/DerivedData/*
rm -rf ~/Library/Caches/com.apple.dt.Xcode/*
open /Applications/Xcode.app
var mediaJSON = { "categories" : [ { "name" : "Movies",
"videos" : [
{ "description" : "Big Buck Bunny tells the story of a giant rabbit with a heart bigger than himself. When one sunny day three rodents rudely harass him, something snaps... and the rabbit ain't no bunny anymore! In the typical cartoon tradition he prepares the nasty rodents a comical revenge.\n\nLicensed under the Creative Commons Attribution license\nhttp://www.bigbuckbunny.org",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" ],
"subtitle" : "By Blender Foundation",
"thumb" : "images/BigBuckBunny.jpg",
"title" : "Big Buck Bunny"
},
{ "description" : "The first Blender Open Movie from 2006",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4" ],
@derhuerst
derhuerst / intro.md
Last active February 22, 2024 17:30
Installing Git on Linux, Mac OS X and Windows