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
EditorConfigで導くコードの「美しさ」
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
ASKUL Engineer
March 14, 2022
Technology
670
0
Share
EditorConfigで導くコードの「美しさ」
@MxShun
https://rakus.connpass.com/event/238395/
ASKUL Engineer
March 14, 2022
More Decks by ASKUL Engineer
See All by ASKUL Engineer
いまさら聞けないAWS
askul
0
6.5k
CTOが語る、テックカンパニーに向けた未来の話。by アスクル
askul
0
210
チームでリーダブルコードを実現するには?
askul
0
3.3k
ラズパイを使ってスマートリモコンを作ってみた
askul
0
870
Discord Bot はじめの一歩
askul
0
730
10分で「エラスティックリーダーシップ」をアウトプット
askul
1
3.9k
1on1をする上で大切なこと
askul
1
890
JBUG東京#20 〜そこが知りたい!Backlog活用術〜
askul
1
3.5k
GCPを活用した物流倉庫内の異常検知/Anomaly detection in distribution warehouse using GCP
askul
0
3.6k
Other Decks in Technology
See All in Technology
さきさん文庫の書籍ができるまで
sakiengineer
0
320
なぜハノーバーメッセに行くべきなのか 〜初参加だから語れること〜
tanakaseiya
0
180
『家族アルバム みてね』における インシデント対応との向き合い方 / Approach incident response in Family Album
kohbis
2
280
Unlocking the Apps
pimterry
0
120
ITエンジニアを取り巻く環境とキャリアパス / A career path for Japanese IT engineers
takatama
4
1.8k
最低限これだけ押さえれ大丈夫_Claude Enterprise/Team企業展開ガバナンス入門
tkikuchi
1
560
ルールやカスタム機能、どう使う?理想の出力を引き出すために今知りたいIBM Bob 5つの機能
muehara
0
150
大学生が本気でDatabricksを活用してDiscordサークルをデータ駆動させてみた
phantomjuju
1
300
地元にいないローカルオーガナイザーの立ち回り
uvb_76
1
390
「コーディング」しない人のための Claude Code 入門 ChatGPT の次の一歩 — 業務に組み込む 育成・共有・自動化
rfdnxbro
1
410
オンコールの負荷軽減のためのBits Assistant 活用方法 / How to Use Bits Assistant to Reduce the Workload on On-Call Staff
sms_tech
1
350
個人の発見を、組織の知恵に 〜生成AI活用を"探索"から"組織の仕組み"へ〜
kintotechdev
2
190
Featured
See All Featured
30 Presentation Tips
portentint
PRO
1
310
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2k
The Language of Interfaces
destraynor
162
26k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
570
Practical Orchestrator
shlominoach
191
11k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.9k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.1k
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
580
WENDY [Excerpt]
tessaabrams
11
38k
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
710
Making Projects Easy
brettharned
120
6.7k
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
190
Transcript
EditorConfig で導く コードの「美しさ」 アスクル株式会社 三浦 駿
自己紹介 三浦 駿 @MxShun 20年 20年10月~ サイト統合PJに参画 21年 21年11月~ スクラムマスターを担う
屋外でエンジニアリングするのがマイブーム 4月~ アスクル株式会社 フルスタックエンジニア(になりたい) 6月~ PJの品質向上隊として活動
弊社紹介 事業所向け(BtoB)通信事業 事業所向け通販サービス 一般消費者向け通販サービス
本日の内容 • コードの「美しさ」を保ちましょう • (いまさらですが)EditorConfig 便利です
コードの「美しさ」とは Good source code should be just as “easy on
the eyes.” • Use consistent layout, with patterns the reader can get used to. • Make similar code look similar. • Group related lines of code into blocks. “The Art of Readable Code” Chapter 4. Aesthetics より引用
コード「美しさ」をめぐる議論 インデントは Tab?空文字? サイズは? 末尾行は入れる?入れない? 改行コードは LF?CRLF?
EditorConfig エディタやIDEを跨いてコードフォーマットを管理・統一する仕組み .editorconfig ファイルで構成を管理する
EditorConfig Properties • indent_style • indent_size • tab_width • end_of_line
• charset • trim_trailing_whitespace • insert_final_newline • max_line_length *詳しくは EditorConfig GitHub wiki “EditorConfig Properties” を参照のこと “tab” か “space” “tab” か 任意サイズ 任意サイズ “lf” か “crlf” か “cr” 選択 選択 選択 “off” か 任意サイズ(一部エディタのみ)
EditorConfig と Lint の掛け合わせ ktlint* は EditorConfig の設定を見て静的コード解析をしてくれる つまりコードフォーマットを包括的に管理ができる *Kotlin
向け Linter のデファクトスタンダード
本日の内容 • コードの「美しさ」を保ちましょう • (いまさらですが)EditorConfig 便利です
告知 https://www.askul.co.jp/kaisya/dx https://tech.askul.co.jp