Skip to content

Instantly share code, notes, and snippets.

View hiz8's full-sized avatar

iji hiz8

View GitHub Profile
@hiz8
hiz8 / checkTypes.js
Created May 22, 2018 09:50
型チェック
function checkType(target, type) {
const result = Object.prototype.toString.call(target).slice(8, -1) === type ? true : false;
return result;
}
@hiz8
hiz8 / 2017.12.05_Moning-Memo.md
Last active December 4, 2017 10:09
2017.12.05_メモ

2017.12.05_メモ

デザイナーの深津さんが最近、noteというWebサービスのUX改修を行っているのだが、その内容を積極的にnoteでアウトプットしていて、内容が為になるし面白い。

深津さんのnote

かなりコンスタントに発信している。

@hiz8
hiz8 / ff_addon.md
Created November 20, 2017 07:30
Firefox Quantam (v57~) 対応アドオン集
@hiz8
hiz8 / dropdown.js
Last active October 26, 2015 03:17
ES6 Dropdown.js
/**
* Example:
* var items = document.getElementById("dropdown").children;
* var dropdown = new Dropdown(items);
*/
(function (window) {
"use strict";
class Dropdown {
@hiz8
hiz8 / example.md
Last active October 25, 2015 23:47
Get query string values in ES6.

Get query string values in ES6.

class GetParams {
  constructor(name) {
    this.name = name.replace(/[\[]/, "\\[").replace(/[\]]/, "\\]");
  }

  run() {
 const regex = new RegExp("[\\?&]" + this.name + "=([^]*)"),
@hiz8
hiz8 / memo.css
Created June 8, 2015 01:10
安全でアクセシブルなアイコン・フォント
.icon-fallback-img .icon-hamburger {
width: 1em;
height: 1em;
background: url("fonts/png/hamburger.png") no-repeat;
}
/* A-Grade */
.supports-fontface .icon-fallback-img .icon-hamburger:before {
font-family: icomoon;
content: "\e601";
}
@hiz8
hiz8 / sass-start.bat
Created May 10, 2015 15:31
SASS watchスタート用バッチファイル
cd /d %~dp0
:: 現在のディレクトリに移動
sass --style expanded --watch style.scss:style.css --cache-location sass/.sass-cache
:: 【--style】CSSのフォーマット
:: 【--watch】scssファイルの自動監視
:: 【sass:html/css】sassファイルの場所:cssファイルの書き出し先
:: 【--cache-location】キャッシュファイルの保存先
@hiz8
hiz8 / text.md
Created January 21, 2015 06:03
WindowsへNodist経由でNode.jsをインストールする

WindowsへNodist経由でNode.jsをインストールする

Nodistを入手

Nodist

  • zipをダウンロード
  • 適当なフォルダへ入れる(例:C:\Users\ユーザー名\nodist)
  • 環境変数を設定
  • PATH=...\nodist\bin (nodist.cmd があるパス)
@hiz8
hiz8 / text.md
Last active August 29, 2015 14:13
mod_expires マニュアル

Apacheのmod_expiresを利用したキャッシュコントロール

mod_expiresの書式

ExpiresDefault "<base> [plus] {<num> <type>}*"
ExpiresByType type/encoding "<base> [plus] {<num> <type>}*"