This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#JSON | |
#特に色指定の必要が無ければ"color"はいりません。 | |
[ | |
{ | |
"datas":[ | |
{"name": "Array A","color": "#DD421D","data":[140,200,250,260,380,400,500,550,650,800]}, | |
{"name": "Array B","color": "#E27E1A","data":[80,90,110,180,210,210,230,240,250,280]}, | |
{"name": "Array C","color": "#EF9E1D","data":[170,180,230,240,260,270,280,330,340,350]}, | |
{"name": "Array D","color": "#AAC40E", "data":[40,50,130,250,180,160,150,160,140,130]}, | |
{"name": "Array E","color": "#76B711","data":[20,30,50,60,65,70,90,110,115,120]}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chart1.append("text") | |
.text(function(d){if(d.Title.length <= 23){return d.Title;} else if (d.Title.length > 23){txt = d.Title.substr(0,21)+'…';return txt;}}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#下記要素にSVGの要素を描画する | |
<div><svg class="chart1"></svg></div> | |
#D3.jsでSVG要素を描画後、要素をアップデートする前に下記のようにg要素を削除する | |
d3.selectAll("chart1 > g").remove() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##階層構造をわかりやすくするためインデントしていますが、実際のデータは行頭に空白を入れると改行を意味するため、空白は入れません。 | |
##コメント行を入れていますがコメントを意味する記号が本当は何か不明。 | |
BEGIN:VCALENDAR | |
PRODID: -//ex skip-dog.net//Manually #クリエイターの識別子。必須。 | |
METHOD:PUBLISH | |
VERSION: 2.0 #必須 | |
BEGIN:VTIMEZONE #以下タイムゾーン | |
TZID:Japan |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!--とりあえず自治会名ー地区名のリストを書き出してみます。--> | |
<ul> | |
{% for sz in szs %} | |
<li>{{sz.jichitai}}: | |
<!--collenction_nameでReferenceProperty型のオブジェクトを取得--> | |
{% for x in sz.funens %} | |
{{x.funen}} | |
{% endfor %} | |
</li> | |
{% endfor %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##loop.index0 でenumerate()のようなインデックスを取得できる | |
{% for item in items.binkans %} | |
BEGIN:VEVENT | |
UID:shizu-gomi.binkan{{loop.index0}}.{{params.today}} | |
DTSTAMP:{{params.today}} | |
SUMMARY:ビン缶ゴミ回収日 | |
LOCATION:{{items.jichitai}} | |
DESCRIPTION:清水区{{items.jichitai}}の缶ビンゴミ回収日 | |
DTSTART;TZID=Japan:{{item.binkan}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysqladmin -i10 processlist status -u root -p |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for val in query: | |
name = val.key().name() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Preferences > Plugins > Browse repositoriesで"LESS CSS Compiler"をインストールする | |
。 | |
2) 環境をリスタートし、Preferences > LESS ProfilesでLESSソースディレクトリ、アウトプットするCSSディレクトリを入力する。"include files by path"はとりあえず *.lessにしている。あらかじめprojectにless用、css用のディレクトリを作っておく。 | |
3) lessのコンパイルは右クリック> compile to css | |
4) File Watcherが設定されているとlessファイルに変更が加わったら即時的にCSSにコンパイルされるようになる。File Watcherの設定項目は自動的に入力されていたり、program pathだけ入力されていなかったりいろいろ。 | |
program pathは自分のmacの場合は/usr/bin/lessだった。 | |
winではlessc.cmdファイルへのパスを指定するらしい。 |
OlderNewer