Skip to content

Instantly share code, notes, and snippets.

View MrHallows's full-sized avatar
🎯
Still waiting for my fellow Americans to wake the fuck up before it's too late.

MrHallows MrHallows

🎯
Still waiting for my fellow Americans to wake the fuck up before it's too late.
View GitHub Profile
@idettman
idettman / json-util.js
Created June 6, 2017 03:23
JSON Utils
/**
* Check for equality between two objects based on JSON stringification
* @param {Object} objectA
* @param {Object} objectB
*/
export const jsonStringifyEquality = (objectA, objectB) => {
return JSON.stringify(objectA) === JSON.stringify(objectB);
}
@JBlond
JBlond / bash-colors.md
Last active May 10, 2025 22:40 — forked from iamnewton/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@brayhoward
brayhoward / convert_aax_files.md
Last active May 8, 2021 21:20
Directions for converting Audible audiobook files, .aax, to .m4a files
@lihsai0
lihsai0 / FormatJson.js
Created December 29, 2017 03:11
[Utils] Useful codes #utils
function formatJson (json, options) {
let reg = null;
let formatted = '';
let pad = 0;
let PADDING = ' ';
options = options || {};
options.newlineAfterColonIfBeforeBraceOrBracket = options.newlineAfterColonIfBeforeBraceOrBracket === true;
options.spaceAfterColon = options.spaceAfterColon === false;
if (typeof json !== 'string') {
json = JSON.stringify(json);
@savokiss
savokiss / Net.js
Created December 31, 2017 14:20
Utils
const Net = (function(exports) {
/**
* 在页面里动态嵌入js最轻量的方法
* @param {string} url get请求的参数,防止缓存的随机数,jsoncallback都应该手动加在这里
* @param {Object|function} op 配置参数或回调函数,op.charset表示js文件的编码
*/
exports.getScript = function(url, op){
var s = document.createElement("script");
s.type = "text/javascript";
#!/bin/sh
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash boot boot.img
fastboot flash logo logo.bin
fastboot flash recovery recovery.img
fastboot flash dsp adspso.bin
fastboot flash oem oem.img
fastboot flash system system.img_sparsechunk.0
fastboot flash system system.img_sparsechunk.1
// ==UserScript==
// @name DuckDuckGo DeepDark
// @namespace http://userstyles.org
// @description <p>
// @author RaitaroH
// @homepage https://userstyles.org/styles/135954
// @run-at document-start
// @version 0.20180103060610
// ==/UserScript==
(function() {var css = "";
@simeonpashley
simeonpashley / Untitled-2
Created July 16, 2018 11:03
Sticky header
//sticky
$(function() {
// Hide Header on on scroll down
var didScroll = false;
var lastScrollTop = 0;
var delta = 5;
var navbarHeight = $('.c-header').outerHeight() + 30;
if ($(window).scrollTop() == 0) {
$('.c-header').addClass('js-at-top');
@muddassirm
muddassirm / LoadJson1.dart
Last active April 26, 2021 18:04
Display JSON data in Flutter : Using the main() function
import 'package:flutter/material.dart';
import 'dart:convert';
import 'dart:async' show Future;
import 'package:flutter/services.dart' show rootBundle;
class Student {
String studentId;
String studentName;
int studentScores;
Student({this.studentId, this.studentName, this.studentScores});
@muddassirm
muddassirm / LoadJson2.dart
Created August 24, 2018 18:18
Display JSON data in Flutter : Using the setState() method
import 'package:flutter/material.dart';
import 'dart:convert';
import 'dart:async' show Future;
import 'package:flutter/services.dart' show rootBundle;
class Student {
String studentId;
String studentName;
int studentScores;
Student({this.studentId, this.studentName, this.studentScores});