-
green -> グリーン
-
red -> レッド
リスト名直後の「グリーン」「レッド」にはかっこを付けない方で統一?
- 原則として全角半角の間にスペースを置かない(今はかなり不揃い)
// Code generated by go-bindata. | |
// sources: | |
// asset/conf.json | |
// DO NOT EDIT! | |
package main | |
import ( | |
"bytes" | |
"compress/gzip" |
# kazzさん謹製 | |
module MyModlue | |
class BaseClass | |
def public_method | |
'called public_method' | |
end | |
def call_methods_with_self | |
puts self.public_method rescue puts 'CANNOT call public_method' | |
puts self.protected_method rescue puts 'CANNOT call protected_method' |
# hachi8833 | |
## お仕事 | |
BPS株式会社で技術ブログ「TechRacho」を運営しています。RailsチュートリアルとRailsガイドを翻訳しました。 | |
正規表現が好き。 | |
プライベートではなぜかGo言語でGobyというRubyライクな言語のメンテを手伝ったりなんかしています。 | |
## 最近の課題 |
<iframe src="https://docs.google.com/presentation/d/e/2PACX-1vQrS0wzkaS6hvy7Era6Iz6Gx12TNp83OtWQ4nh3iJMW3ywViiaLgjYAORUtH5PKLHyg-k-Ecv_L7yAu/embed?start=false&loop=false&delayms=3000" frameborder="0" width="960" height="569" allowfullscreen="true" mozallowfullscreen="true" webkitallowfullscreen="true"></iframe> |
# Sandi Metz「オブジェクト指向設計実践ガイド」でリファクタリング後のduck-typingコードを美しいと思い | |
# それに触発されて書いたHello worldです。 | |
# なおこのコードはRubyとGobyどちらでも動きます。 | |
# Greetクラス | |
class Greet | |
attr_accessor :audience, :head, :tail | |
def initialize | |
@head = 'Hello, ' |
type Digits = /* 上記参照 */; | |
type DigitsStr = `${Digits}`; | |
type Tile<T extends unknown[], N extends Digits | DigitsStr | 10 | '10'> = [ | |
[], | |
[...T], | |
[...T, ...T], | |
[...T, ...T, ...T], | |
[...T, ...T, ...T, ...T], | |
[...T, ...T, ...T, ...T, ...T], | |
[...T, ...T, ...T, ...T, ...T, ...T], |
function delay(t){ | |
return new Promise(function(resolve){ | |
return setTimeout(resolve, t) | |
}); | |
} | |
function logHi(){ | |
console.log('hi'); | |
} | |
delay(2000).then(logHi); |
new Promise(function(resolve, reject) { | |
setTimeout(() => resolve(1), 2000); | |
}).then((result) => { | |
alert(result); | |
return result + 2; | |
}).then((result) => { | |
alert(result); | |
return result + 2; | |
}).then((result) => { |