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
リーダブルコード読書会 #1
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Kenta Enomoto
July 17, 2014
Programming
350
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
リーダブルコード読書会 #1
社内リーダブルコード読書会 #1
Kenta Enomoto
July 17, 2014
More Decks by Kenta Enomoto
See All by Kenta Enomoto
調理場で使うタブレット専用アプリ をどうつくったか -STORES モバイルオーダー 実装の舞台裏-
enomotok
0
29
[DroidKaigi 2025] 共有と分離 - Compose Multiplatform "本番導入" の設計指針
enomotok
0
44
Kotlin Multiplatform / Compose Multiplatform を活用したモバイルアプリ開発の最前線
enomotok
0
140
Compose MultiplatformにおけるiOSネイティブ実装のベストプラクティス
enomotok
1
500
STORES ブランドアプリのスケールするアプリづくり
enomotok
0
94
What's new in Xcode 16 ダイジェスト
enomotok
0
870
Introducing Pkl
enomotok
0
3.1k
iOS リポジトリへの Renovate の導入
enomotok
2
440
iOS開発とGitLab CI
enomotok
7
4.1k
Other Decks in Programming
See All in Programming
エージェンティックRAGにAWSで入門しよう!
har1101
7
1.1k
「AIで開発し、AIを届ける」をEvalでつなぐ 〜AIネイティブに始めるプロダクト開発の実践〜 / Connecting "Develop with AI, deliver AI" with Eval
rkaga
4
2.4k
Spec-Driven Development with AI-Agents: From High-Level Requirements to Working Software
antonarhipov
2
450
決定論的オーケストレーションの設計と実装 / Design and Implementation of Deterministic Orchestration
nrslib
3
1.1k
AIチームを指揮するOSS「TAKT」活用術 / How to Use “TAKT,” an OSS Tool for Orchestrating AI Teams
nrslib
6
830
Copilot CLI の継戦能力を高める コンテキスト管理
nozomutu
1
1.2k
ユニットテストの先へ:テスト技法で要求・仕様を整理するJava開発実践 / Beyond_Unit_Testing_Practical_Java_Development_Techniques_for_Organizing_Requirements_and_Specifications
shimashima35
0
350
Claspは野良GASの夢をみるか
takter00
0
170
Javaの型とAI時代に型が大事な理由 / java types and type in AI era
kishida
2
110
権限チェックの一貫性を型で守る TypeScript による多層防御
mnch
4
1.1k
Datadog × OpenTelemetry 入門と実践のあいだ
kn_to_maxpno
1
140
oxlintはeslint/typescript-eslintを置き換えられるのか
shomafujita
2
320
Featured
See All Featured
Principles of Awesome APIs and How to Build Them.
keavy
128
17k
SEO for Brand Visibility & Recognition
aleyda
0
4.6k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
350
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
370
エンジニアに許された特別な時間の終わり
watany
107
250k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
62
54k
We Have a Design System, Now What?
morganepeng
55
8.2k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
1
200
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
300
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
160
4 Signs Your Business is Dying
shpigford
187
22k
Transcript
Ϧʔμϒϧίʔυಡॻձ
͓ू·Γ͍͖ͨͩ͋Γ͕ͱ͏ ͍͟͝·͢ɻ
w ಡॻձͷత w Ϧʔμϒϧίʔυʹ͍ͭͯ w ಡॻձͷਐΊํ ͓͠ͳ͕͖
ಡॻձͷత
w ྑ͍ίʔυͷॻ͖ํΛʹ͚ͭΔ w ʑͷษڧͷ͕͔Γʹ ಡॻձͷత
w ྑ͍ίʔυͷॻ͖ํΛʹ͚ͭΔ w ʑͷษڧͷ͕͔Γʹ w ϓϩάϥϛϯάʹ͍ͭͯؾܰʹͤΔ ಡॻձͷతʢͦͯ͠ཪςʔϚʣ
Ϧʔμϒϧίʔυʹ͍ͭͯ
None
ಡΈ͍͢ίʔυͷॻ͖ํΛ ղઆͨ͠ຊ
ίʔυίϯϓϦʔτͷ༰Λ ؆୯ʹ·ͱΊͨͷʁ
ɺͷίϯϐϡʔ λؔ࿈ॻ੶ͷؒച্Ґ ʢδϡϯΫಊௐʣ
ϦʔμϒϧίʔυͰ͍͏ ʮྑ͍ίʔυʯͬͯʁ
ͦΕ ʮཧղ͍͢͠ίʔυʯ
Qཁม ! if (request.user.id == document.owner_id) {! // Ϣʔβ͜ͷจॻΛฤू͢Δ! }!
! …! ! if (request.user.id != document.owenr_id) {! // จॻಡΈऔΓઐ༻! }
Qཁม ! if (request.user.id == document.owner_id) {! // Ϣʔβ͜ͷจॻΛฤू͢Δ! }!
! …! ! if (request.user.id != document.owenr_id) {! // จॻಡΈऔΓઐ༻! }
Qཁม ! if (request.user.id == document.owner_id) {! // Ϣʔβ͜ͷจॻΛฤू͢Δ! }!
! …! ! if (request.user.id != document.owenr_id) {! // จॻಡΈऔΓઐ༻! } ! final boolean user_owns_document = (request.user.id == document.owner_id);! ! if (user_owns_document) {! // Ϣʔβ͜ͷจॻΛฤू͢Δ! }! ! …! ! if (!user_owns_document) {! // จॻಡΈऔΓઐ༻! }
if (!(file_exists && !its_protected)) Error("Sorry, could not read file."); QυɾϞϧΨϯͷ๏ଇΛ͏
QυɾϞϧΨϯͷ๏ଇΛ͏ if (!(file_exists && !its_protected)) Error("Sorry, could not read file.");
if (!file_exists || is_protected) Error("Sorry, could not read file.");
ಡॻձͷਐΊํ
͡ΊΑ͏