LoginSignup
7
7

More than 5 years have passed since last update.

StyleDocco導入(windows編)

Posted at

StyleDocco導入(windows編)

  • コーダー向けにCygwinは使わず、Windows上だけで完結するようにしてみました

事前準備

msys-git

  • Windows向けgit

python2.7+

  • python(nvmwの実行に必要)

nvmw

  • Windows向けのnode.jsのバージョン管理ツール

補足

  • msys-gitとpython2.7はパッケージインストールなので簡単です。
  • nvmwもgithubのコマンドをコマンドプロンプトにコピペでいけます。

nvmwをインストールしたら

コマンドプロンプト上で

peter> nvmw install v0.10.8
peter> nvmw use v0.10.8
peter> node -v
v0.10.8
  • これでnode.js(v0.10.8)がインストールできました。
  • 0.11.x系はまだ不安定なので0.10.x系を使いました。

StyleDocco

  • CSSスタイルのドキュメントジェネレーター
  • 作業効率が2倍に!(なるらしい)

インストール方法

 peter> npm install -fg styledocco

実行方法

cssファイルを作成

/* Provides extra visual weight and identifies
 the primary action in a set of buttons.
<button class="btn primary">Primary</button> */
.btn.primary {
    background: blue;
    color: white;
}

上記はgithubからコピペ

  • 上記のコードをexampleフォルダにbutton.cssというファイル名で保存する
注意点
  • ReadMe.mdに説明を書いてexampleフォルダにいれるとindex.htmlとして表示される
  • なのでindex.cssというファイルはstyledoccoで使われるので使ってはいけないぽい

styledoccoコマンドを実行

styledocco example
  • docsというフォルダにドキュメントが出力される
  • 詳しい使い方はstyledoccoのgithubをみてね
7
7
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
7
7