Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Stylelintの取扱説明書
Search
moro
October 03, 2019
Programming
800
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Stylelintの取扱説明書
moro
October 03, 2019
Other Decks in Programming
See All in Programming
初めてのKubernetes 本番運用でハマった話
oku053
0
130
共通化で考えるべきは、実装より公開する型だった
codeegg
0
260
Foundation Models frameworkで画像分析
ryodeveloper
1
130
ローカルLLMでどこまでコードが書けるか -縮小版 / How much code can be written on a local LLM Shortened
kishida
2
200
JAWS-UG横浜 #102 AWSサ終供養LT会 成仏できない AWS サービスたち 〜本日、三体供養します〜
maroon1st
0
220
Claude Opus 4.6以後の受託開発エンジニアの変化(Claude Code開発ノウハウ大公開スペシャルbyクラスメソッド)
iidatakuma
1
820
PHPだって関数型したい 〜できること、できないこと〜 / fp-in-php
jsoizo
0
240
AIキャラアプリkaiwaの低遅延音声通話基盤をどう作ったか - AWS Gravitonで支える低遅延・低コストAI Agent基盤
mogamit
0
180
自作OSでスライド発表する
uyuki234
1
3.9k
音楽のための関数型プログラミング言語mimiumにおける多段階計算の活用
tomoyanonymous
1
350
Honoでのサプライチェーン侵害対策 〜 3つのライブラリに学ぶ
yusukebe
7
1.9k
act2-costs.pdf
sumedhbala
0
120
Featured
See All Featured
Site-Speed That Sticks
csswizardry
13
1.3k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.1k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Odyssey Design
rkendrick25
PRO
2
730
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.2k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
270
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
220
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
360
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
660
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
640
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
37
6.5k
The Limits of Empathy - UXLibs8
cassininazir
1
520
Transcript
Stylelintの 取扱説明書 2019年10月3日 Meguro.css@ラクスル 電気通信大学 実質4年 moro
自己紹介 名 前 moro 出 身 埼玉県 職 業 学生
年 齢 (才) 22 ツ イ ッ タ ー @mo__ro__ ス キ ル React, CSS • 大学2年の終わりに大学を休学。 • 紆余曲折あり現在休学2年目に突入。 • 大学に戻る気はもうなさそう。
もくじ • 概要紹介 • 使用前の準備 • 動作確認 • 上手な使い方
概要紹介
そもそも、Stylelintって? 概要紹介
潜在的なエラーを発見し スタイルに一貫性を持たせるのを 助けてくれるツール 概要紹介
簡単な例 概要紹介
潜在的なエラー 概要紹介
潜在的なエラー “collorなんてプロパティ知らないぞっ” stylelintより 概要紹介
スタイルの統一 概要紹介
スタイルの統一 “オマエのチームだと’#FFF’じゃなくて’#fff’らしいぜ” stylelintより 概要紹介
使用前の準備
使用前の準備 必要なもの Stylelint Config
だけ
手順1. npmモジュールをインストール または 手順2. プロジェクトのルートディレクトリに .stylelintrc.json を作成 使用前の準備
手順3. configファイルを編集 今回は勝手におすすめの設定をしてくれる stylelint-config-standard を使用 詳細はこちら: https://github.com/stylelint/stylelint-config-standard または 使用前の準備
.stylelintrc.json 使用前の準備
だけ
動作確認
上手な使い方
上手な使い方 1. メッセージのカスタマイズ
上手な使い方 Stylelint導入後のある日...
上手な使い方 アンチCSSの Kさん 仕方ねえ、 仕事だしCSS書くかあ
アンチCSSの Kさん 上手な使い方 “オマエのチームだと’#FFF’じゃなくて’#fff’らしいぜ” stylelintより
上手な使い方 アンチCSSの Kさん 誰だ こんなツール入れたの
上手な使い方 Q. Kさんはなぜイラついた?
上手な使い方 A. メッセージがあまりにも無機質だったから
上手な使い方 .stylelintrc.json 解決策
上手な使い方 仕方ねえ、 直すか。。。。
上手な使い方 2. husky & lit-staged
huskyとは commitやpushの前に タスクを走らせてくれる
lit-stagedとは stagingファイルに対して lintを走らせてくれる
上手な使い方 つまり
上手な使い方 lintがかかっていないファイルの commitを防ぐことができる
上手な使い方 package.json
上手な使い方 lintエラーを含んだCSSファイルをコミットしようとすると...
上手な使い方 ただし
上手な使い方 気をつけましょう
おまけ
おまけ インターン先 / 就職先 大募集中でございます。 Twitter: @mo__ro__
None