Skip to content

Instantly share code, notes, and snippets.

View ShinyChang's full-sized avatar
🏠
Working from home

Shiny ShinyChang

🏠
Working from home
View GitHub Profile
module.exports = {
...
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
use: [
'thread-loader',
'babel-loader'
ngrok http 80
echo "NODE_EXTRA_CA_CERTS=$(mkcert -CAROOT)/rootCA.pem" >> .env
require('dotenv').config();
const https = require('https');
const path = require('path');
const fs = require('fs');
const Express = require('express');
const app = new Express();
app.get('/', (req, res) => res.send('Hello World!!'));
mkcert --cert-file localhost.pem --key-file localhost-key.pem localhost
brew install mkcert
brew install nss
mkcert -install
<?php
header('Access-Control-Allow-Origin: *');
header('Cache-Control: private');
header('Pragma: no-cache');
Header('Connection: Keep-Alive');
Header('Proxy-Connection: Keep-Alive');
Header('Content-Type: application/json;charset=UTF-8');
// generate 2k garbage data
foreach (range(0, 2048) as $key => $value) {
@ShinyChang
ShinyChang / Preferences.sublime-settings
Created October 15, 2015 03:24
Sublime Text 3 Settings - User
{
"added_words": // 新增到字典的單字
[
"php",
"href",
"td"
],
"always_show_minimap_viewport": true, // 永遠顯示 minimap 目前顯示的區域
"binary_file_patterns":
[
<!DOCTYPE html>
<html>
<head>
<script src="http://blueimp.github.io/JavaScript-MD5/js/md5.js"></script>
<script src="http://fb.me/react-with-addons-0.13.1.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
<body>
@ShinyChang
ShinyChang / google.user.js
Last active November 30, 2018 10:55
VoiceTube User Defined JavaScript
+(function(){
"use strict";
// only for google.com
if (!window.location.host.match(/google.com/)) {
return;
}
var input = document.querySelector("input[name=q]");