Skip to content

Instantly share code, notes, and snippets.

View visioncan's full-sized avatar
💭
I may be slow to respond.

VCAN visioncan

💭
I may be slow to respond.
View GitHub Profile
@visioncan
visioncan / font-casks.md
Last active August 28, 2021 18:46
Font Casks

sh:

curl -L https://gist.githubusercontent.com/visioncan/6a5453f77649add27aa4155cc8015070/raw/24a783352dd1acdc9418931737f9378fea06c0ff/font-taipei-sans.rb > font-taipei-sans.rb

curl -L https://gist.githubusercontent.com/visioncan/6a5453f77649add27aa4155cc8015070/raw/24a783352dd1acdc9418931737f9378fea06c0ff/font-lxgw-wen-kai-light.rb > font-lxgw-wen-kai-light.rb

curl -L https://gist.githubusercontent.com/visioncan/6a5453f77649add27aa4155cc8015070/raw/24a783352dd1acdc9418931737f9378fea06c0ff/font-lxgw-wen-kai.rb > font-lxgw-wen-kai.rb

@visioncan
visioncan / changelog-tpl.hbs
Last active January 27, 2021 10:42
changelog-tpl
### Changelog
{{#each releases}}
{{#if href}}
###{{#unless major}}#{{/unless}} [{{title}}](#{{title}})
{{else}}
#### {{title}}
{{/if}}
{{#if tag}}
@visioncan
visioncan / shopping_spec.md
Last active September 20, 2018 08:00
購物站相關中英文名詞

購物相關中英文對照表:

name 說明
item 單一品項
description 描述
image 圖片
sku Stock Keeping Unit 單品項管理,通常給客戶填,內部使用
price 價格
sale_price 優惠價格
@visioncan
visioncan / command.sh
Last active May 17, 2017 07:13 — forked from peterdemartini/command.sh
Exclude node_modules in TimeMachine,在 TimeMachine 排除 node_modules 資料夾
find `pwd` -type d -maxdepth 3 -name 'node_modules' | xargs -n 1 tmutil addexclusion
@visioncan
visioncan / function_invocation.js
Created April 10, 2017 13:57 — forked from myshov/function_invocation.js
11 Ways to Invoke a Function
console.log(1);
(_ => console.log(2))();
eval('console.log(3);');
console.log.call(null, 4);
console.log.apply(null, [5]);
new Function('console.log(6)')();
Reflect.apply(console.log, null, [7])
Reflect.construct(function(){console.log(8)}, []);
Function.prototype.apply.call(console.log, null, [9]);
Function.prototype.call.call(console.log, null, 10);
@visioncan
visioncan / http.html
Last active June 1, 2016 17:17
iframe cross domain communication
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Http</title>
</head>
<body>
<h1>http page</h1>
<iframe src="https://sub.domain.dev/https.html" frameborder="0" id="ff"></iframe>
<script>
@visioncan
visioncan / font-source-han-sans-J.rb
Last active October 17, 2016 12:09
Casks font-source-han-sans
cask :v1 => 'font-source-han-sans-J' do
version '1.004'
sha256 '035fe4f72eabb45aff8f2ba29382db67a86918ee6c537281c04b7c7cb179e3fb'
url "https://github.com/adobe-fonts/source-han-sans/raw/release/OTF/SourceHanSansJ.zip"
homepage 'https://github.com/adobe-fonts/source-han-sans'
name 'Source Han Sans J'
font "SourceHanSansJ/SourceHanSans-Bold.otf"
font "SourceHanSansJ/SourceHanSans-ExtraLight.otf"
@visioncan
visioncan / gist:b7c26d683f8acd0d5073
Created July 7, 2015 01:57
Sublime text theme use SanFranciscoDisplay font face
//========================================================
// TAB LABELS
//--------------------------------------------------------
{
"class": "tab_label",
"fade": true,
"fg": [170,170,170],
"font.face": "SanFranciscoDisplay-Regular"
},
// Sidebar heading
@visioncan
visioncan / .scss-lint.yml
Last active August 29, 2015 14:09
scss-lint 設定
# Default application configuration that all configurations inherit from.
scss_files: "sass/**/*.scss"
linters:
BangFormat:
enabled: true
space_before_bang: true
space_after_bang: false
# Border 使用 0 不使用 none
@visioncan
visioncan / Map_module.scss
Created November 9, 2014 06:25
模組裡 map merge 寫法
//////////////////////////////////// 版的css設定
$list: (
li:(
background-color: #fff
)
);
//////////////////////////////////// 模組scss -----------------------
$list: () !default;