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
Making mock-up in web application
Search
Kusamao Abe
August 07, 2018
Programming
0
78
Making mock-up in web application
Kusamao Abe
August 07, 2018
Tweet
Share
More Decks by Kusamao Abe
See All by Kusamao Abe
Vue builds
kusamao
1
460
Javascript in the past and now
kusamao
1
160
The Essence of UI Design
kusamao
1
1.9k
Make good (better) form
kusamao
0
240
Keep a distance from jQuery
kusamao
0
110
Using Heroku on entrusted development
kusamao
0
1.1k
Other Decks in Programming
See All in Programming
テストコード文化を0から作り、変化し続けた組織
kazatohiei
2
1.5k
テストコードのガイドライン 〜作成から運用まで〜
riku929hr
5
940
MCP with Cloudflare Workers
yusukebe
2
220
週次リリースを実現するための グローバルアプリ開発
tera_ny
1
110
良いユニットテストを書こう
mototakatsu
8
3.1k
Spatial Rendering for Apple Vision Pro
warrenm
0
150
開発者とQAの越境で自動テストが増える開発プロセスを実現する
92thunder
1
200
ドメインイベント増えすぎ問題
h0r15h0
2
420
フロントエンドのディレクトリ構成どうしてる? Feature-Sliced Design 導入体験談
osakatechlab
8
4.1k
PHPで学ぶプログラミングの教訓 / Lessons in Programming Learned through PHP
nrslib
4
390
Webエンジニア主体のモバイルチームの 生産性を高く保つためにやったこと
igreenwood
0
340
SymfonyCon Vienna 2025: Twig, still relevant in 2025?
fabpot
3
1.2k
Featured
See All Featured
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.9k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
A Philosophy of Restraint
colly
203
16k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
The Invisible Side of Design
smashingmag
298
50k
Building Better People: How to give real-time feedback that sticks.
wjessup
366
19k
Git: the NoSQL Database
bkeepers
PRO
427
64k
How GitHub (no longer) Works
holman
311
140k
KATA
mclloyd
29
14k
Optimizing for Happiness
mojombo
376
70k
Typedesign – Prime Four
hannesfritz
40
2.4k
Transcript
ϞοΫΞοϓɺ Ͳ͏ӡ༻͢Δʁ 2018/08/04 JAM plus #02 at tambourine commune
҆෦ຑੜ Kusamao Abe גࣜձࣾλϯόϦϯ ʢtambourine.incʣ ɾςΫχΧϧσΟϨΫλʔ ɾWebΤϯδχΞ
JAM plusͷ͓͞Β͍ w JAMελοΫˠJavaScript API MarkUpΒ͍͠ w MEANελοΫͱ͔LAMPͱ͔ͦ͏͍͏ͭ ϑϩϯτΤϯυΛࢦ͢Β͍͠ w
plusͬͯԿˠ͜ͷϏϧͷ໊લ͕ϓϥεϏϧ w ϩΰͱ͔΄͍͠ؾ͕͢Δ
Web੍࡞ʹ͓͚ΔϚʔΫΞοϓ ϫΠϠʔϑϨʔϜ σβΠϯΧϯϓ࡞ ϚʔΫΞοϓ WebαΠτ੍࡞ WebΞϓϦέʔγϣϯ੍࡞ σβΠϯΧϯϓ࡞ ϚʔΫΞοϓ γεςϜઃܭ ϓϩάϥϛϯά
ςετ ཁ݅ఆٛ ϫΠϠʔϑϨʔϜ
ϞοΫΞοϓΛ࡞Δ w ϞοΫΞοϓʢmock-upʣɿ࣮ͱಉ͡େ͖͞ʹ࡞ͬͨܕɻݪੇܕɻ w ਫ਼៛ͳܕΛ࡞Δ͜ͱͰɺ࣮ࡍʹ࣮ͯ͠Έͯग़ͯ͘ΔΛ௵ͨ͠Γɺ ࣮ݱՄೳੑΛνΣοΫͨ͠Γ w ITۀքͰଞͷ࡞ۀϓϩηεʹґଘͤͣʹ੍࡞ΛਐΊ͓͍ͯͯɺޙ͔Βଞ ͷϓϩηεͱΈ߹ΘͤΔ͜ͱ
ଞͷۀքͰ w ۙͳͱ͜ΖͰ͍͑ܞଳిɾεϚʔτϑΥϯͷళ಄ϞοΫΞοϓ w ݐஙۀքͰɺઃܭਤͲ͓Γʹ࡞ΕΔ͔ΛνΣοΫͨ͠Γ w ߤۭػͳͲͰ
5IF(PME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Bʮ͋ͬɺͲ͏͠Α͔ͬʙʯ
࣮Ҋ݅ͱϞοΫΞοϓ 01
ECαΠτ w ཧը໘আ͍ͯύλʔϯ΄Ͳͷը໘͕ඞཁ w PC൛ͷΈͷ੍࡞ͰOK • αʔόαΠυΞϓϦέʔγϣϯ
w ϚʔΫΞοϓͱViewͷΈࠐΈɾ࣮୲ऀ͕ผ w σβΠφʔ͕ுΓ͍͍ͯΔҊ݅Ͱͳ͔ͬͨʢνͰΑ͋͘Δʣ w ը໘ઃܭˠσβΠϯˠϚʔΫΞοϓ w جຊઃܭˠৄࡉઃܭˠ࣮ɹͷ͕ͭฒߦՔಇ w σβΠφʔɿɹϑϩϯτΤϯυɿɹόοΫΤϯυɿ͍ͬͺ͍
ˠσβΠφʔ͕ΧϯϓΛߋ৽͚ͭͮ͠ΔΘ͚Ͱͳ͍ ˠʢ݁ՌతʹʣσβΠφʔ͕ϓϩδΣΫτ్தͰୀ৬
ํ w ࣮͠ऴ͑Δ·ͰϞοΫΞοϓΛʮਖ਼ʯͱͯ͠νΣοΫ w ͍ͭͰ୭Ͱ֬ೝͰ͖ΔΑ͏ʹɺϞοΫΞοϓͷΠϯελϯεΛཱͯΔ w ˠϞοΫΞοϓΛΞϓϦέʔγϣϯͱผͷϦϙδτϦʹ w ݁Ռతʹผʹ͖ͩͬͨ͢ͷ͔͕͋Δʢࣗͷͳ͔Ͱʣ
ߏ w ຊମLaravel • pug w SCSS autoprefixer • gulp
QVH w extend͠·ͬͨ͘ΒϏϧυ͕࣌ؒͲΜͲ͜૿͑Δ w ։ൃ࣌expressmiddlewareͰϦΫΤετ͕དྷͨͷΛ HTMLʹͯ͠ฦͯ͠ɺඞཁͳͱ͖͚ͩϏϧυ͢ΔΑ͏ʹมߋ w svgΛinlineͰຒΊࠐΉͷʹinclude͍·ͬͨ͘Βݟ௨͠ྑ͘ͳͬͨ͠ ϦΫΤετݮͬͨΜ͕ͩHTML͕ϋνϟϝνϟͳݟ௨͠ʹ w
ͳΜ͔ͩΜͩهड़͕গͳ͍ͷͱςϯϓϨʔτϔϧύ͕ଟ͍ͷָ
$44 w {{pageName}}--{{blockName}}__{{modifierName}} ͰCSSηϨΫλΛ౷Ұͯ͠ɺϖʔδ͝ͱʹݻ༗ͷηϨΫλʹ w mixinΛͬͯ෦తʹಉ͡ελΠϧΛཧ ʢ͜ͷ͋ͨΓͷઃܭ·͍͔͍ͨͭͨ͠Ͱ͢Ͷʣ w ΊΜͲ͏ͳͷͰશ෦ϑΝΠϧʹͨ͠ɺkB͘Β͍͋Δʜ w
ECSSͱ͔FLOCSSͱ͔ʹணΛಘͯຐվͨ͠
ผϦϙδτϦʹͯ͠Ͳ͏ͩͬͨʁ w CSSΛ࠷৽masterͷঢ়ଶͰຖϏϧυͯ͠ΞϓϦέʔγϣϯʹ͍࣋ͬͯ͘ ͷ͕compressedͳͷͰ͕ࠩ͋ͬͯΔ͔Θ͔Βͳ͍ w खݩͰϏϧυͨ͠ͱ͖ʹ͏͔ͬΓmaster͕࠷৽͡Όͳ͍ͱσάϨ͢Δ w ͭ·ΓσάϨͨ͠ͱ͍͏͜ͱͰ͢ w ֤͕ࣗΞϓϦέʔγϣϯͷڥߏஙΛ͠ͳͯ͘मਖ਼ରԠ͓ͯ͠٬͞Μɾ
σΟϨΫλʔʹ֬ೝͯ͠Β͑Δͷָͩͬͨ
ਖ਼ϦϙδτϦͭʹ͍ͨ͠
w Ξηοτʹશ෦ೖΕ͓͍ͯͯɺDocumentRootΛΓସ͑ͯσϓϩΠͰ͖ ͨΒϦϙδτϦͭͰΠϯελϯεผʹͰ͖ΔͷͰʁ w HerokuͰProcfileΛͲ͏ʹ͔͢ΕͰ͖ͦ͏ʂ
࣮Ҋ݅ͱϞοΫΞοϓ 02
ϚΠϖʔδܥWebΞϓϦ w ݩϚΠϖʔδͷͳ͍WordPressαΠτ w Ծొˠຊొˠొใͷมߋ͕Ͱ͖ΔܥͷWebΞϓϦʹϦχϡʔΞϧ w ϚΠϖʔδ֎ʹίϯςϯπ͕͋Δ w ϦχϡʔΞϧલ͔ΒϞοΫΞοϓϦϙδτϦ͕ผͰଘࡏ w
ը໘ऑʢશ෦1$41ผͳͷͰ࣮࣭ʣˠϦχϡʔΞϧͰഒ͘Β͍ w ్ͬͪ͜தͰσβΠφʔୀ৬ˠผͷύʔτφʔ͞ΜʹҾ͖ܧ͗
ํ w ϦϙδτϦΛ౷Ұͯ͠ΈΑ͏ w ಉ͡ιʔεϕʔεͷGitϦϙδτϦ͔ΒɺϞοΫڥɾεςʔδϯάΛͦ ΕͧΕHerokuͰσϓϩΠ͍ͨ͠ʢReview Appsʣ w Review AppsɿPull
Request͝ͱʹΠϯελϯε্ཱ͕͕ͪΔ w ຊ൪AWS EC2
ߏ w ຊମLaravel • ejs w SCSS autoprefixer • gulp
FKT w extend͕ͳ͍ͱ͜ΜͳʹͭΒ͍ͷ͔ʂ w <%= %>ɺJISྻͩͱΊͬͪΌଧͪͮΒ͍ؾ͕͢Δ w ػೳ໘Ͱ͍͏ͱੵۃతʹ࠾༻͢Δཧ༝͋Μ·Γͳͦ͞͏ ʢҊ݅։࢝ॳʹ͓ئ͍ͨ͠ϚʔΫΞοϓͷํ͕pugͬͯͳ͔ͬͨʣ
ϦϙδτϦΛ·ͱΊΔ w ejsςϯϓϨʔτΛSFTPVSDFTBTTFUTUFNQMBUFTʹ w SCSSΛSFTPVSDFTBTTFUTTUZMFTIFFUTʹ w ຊ൪༻ϏϧυQVCMJDDTTʹ w ϞοΫΞοϓ༻ʹผͷDocRootͱͯ͠NPDLΛ࡞ w
ը૾ͱ͔શ෦QVCMJD͔ΒNPDLʹίϐʔ͢ΔλεΫΛHVMQͰ࡞ w DocRootڥมͰΓସ͑Δ ʢࢀߟɿIUUQTRJJUBDPNVTLJUFNTFDGFʣ
Heroku Pipeline w develop / staging / productionͷͲ͜ʹAppΠϯελϯεΛஔͯ͠Ͳ͜ʹίʔ υΛద༻͢Δ͔Λ੍ޚͰ͖Δ w
Review AppsΛͬͯɺ Pull Request͕͋ͬͨΒdevelopʹରԠ͢ΔAppΠϯελϯεΛࣗಈͰཱͯ masterʹpush͞ΕͨΒstagingͷAppʹࣗಈσϓϩΠ productionʹखಈͰϘλϯԡͯ͠promoteͤ͞ΔΈ͍ͨͳ͍ํ w ผͷMeetupͰ͠ΌͬͨͷͰࢀߟ·Ͱʹ IUUQTTQFBLFSEFDLDPNLVTBNBPVTJOHIFSPLVPOFOUSVTUFEEFWFMPQNFOU
Review Apps w Review AppsͰʮϞοΫͷPull Requestʯͱʮ௨ৗͷPull RequestʯΛݟ ͚ͯڥมΛΓସ͑ΒΕͳ͍ w ͭ·ΓɺͻͱͭͷPipeline͔ΒͷReview
AppsϞοΫ༻͔௨ৗͷ։ൃ ༻Ͳ͔ͬͪʹ͔͠ద༻Ͱ͖ͳ͍ w ࠓߋ͚ͩͲɺPipelineΛ͚Ε͜Μͳ͜ͱඞཁͳ͔ͬͨ ʢ͜Εॻ͍ͯΔͱ͖·Ͱؾ͕͔ͳ͔ͬͨʣ
։ൃதʙӡ༻ w ։ൃॳظ w ࠷ॳϞοΫ͕Review AppsͰ࡞͞ΕΔΑ͏ʹ͍ͯͨ͠ w ·ͩΞϓϦଆ΄ͱΜͲ৮ͬͯͳ͍ঢ়ଶ w ։ൃޙظ
w ΞϓϦଆΛReview AppsͰදࣔ͞ΕΔΑ͏ʹมߋ w ͋ͱ͔Βݟͨͷௐ͕͋ͬͯͪΐ͍ͪΐ͍Ϛʔδ͔ͯ͠ΒνΣοΫͯͨ͠ w Ϗϧυͨ͠CSSΛ࣋ͬͯ͜ͳ͍͍ͯ͘ͷ͔ͳΓָʢCSS͕ͦͦϑΝΠϧଟ͍ʣ
ϦϦʔεޙ w ϚΠϖʔδ͕ϩʔΧϧͰ֬ೝͰ͖ͳ͍ਓ͕͍ͨ w ϞοΫΛಉ͡ςϯϓϨʔτߏʹ͓͍ͯͯ͠ɺ࣮ࡍͷಈ࡞Λ֬ೝͰ͖ ͳ͍ͷͭΒ͍ w ϞοΫΛ࠷৽ʹอ͓ͬͯ͜͏ͱ͢ΔͱPull Request͕ ͱ͔ʹ
ͳͬͯϨϏϡϫʔ͕ԕ͍Λ͢Δ
Θ͔͖ͬͯͨͧ
ΈΜͳͰ҆શʹ։ൃ͢Δ ͦͦσβΠϯΧϯϓɾϓϩτλΠϓΛߋ৽͠ͳ͍ͱӡ༻͕ͭΒ͍ ͠σβΠϯΧϯϓΛߋ৽͠ͳ͍ͷͩͱͨ͠ΒɺϩʔΧϧϦϞʔτͰ ୭Ͱ֬ೝͰ͖ΔΑ͏ʹ͓͍ͯͯ͠ɺ؆୯ʹࢼͤΔΑ͏ʹ͓ͯ͘͠ ϑΝΠϧΛίϐʔͯ͠ผͷϦϙδτϦʹ͍࣋ͬͯ͘ͷ͏ΊΑ͏ ϞοΫΞοϓͱ࠷ऴతͳςϯϓϨʔτͷॻ͖ํ͕ҧ͏ͷεΠονϯά
ίετ͔͔Δ͠ϛε૿͑Δ
ελΠϧΨΠυͱϞοΫΞοϓ w ελΠϧΨΠυ͋ΔͳΒଟલఏ͕͍Ζ͍Ζҧ͏ w ͦͦΨΠυ͕มΘΔͷେৎͳͷ͔ͱ͍͏ͷͱ͔͘ɺมߋͷ өͱ͔ߟ͑ΔͱΠϯελϯεཱ͕ͬͯͯಉ͡ιʔεϕʔε͡Όͳ͍ͱݫ͠ ͦ͏ w ελΠϧΨΠυ͋ΕϞοΫΞοϓ͕͍Βͳ͍ͷ͔Ͳ͏͔ɺ͍Βͳ͍ؾ ͢Δʢͬͨ͜ͱͳ͍͔Βڭ͑ͯ͘Εʂʂʂʂʣ
͜Ε͔Βͷํ w ϞοΫΞοϓΛͲ͜·Ͱอ͓͔࣋ͯ͘͠ΛઌʹΑ͘ߟ͑Δ w ͳ͋ͳ͋Ͱӡ༻͠ͳ͍ w ελʔτͨ͠Βଟ͍Βͳ͍ͣ w ͠ӡ༻͢ΔͳΒɺϦϙδτϦͭʹ͍ͨ͠ʢҊ݅ʹΑΔ͕ʣ w
Ͱ͖ΕΞϓϦͰ͏ςϯϓϨʔτΤϯδϯͰ࡞ͬͨ΄͏͕͍͍
ͨͱ͑LaravelͳΒ w ࠷ॳ͔ΒbladeͰॻ͘ w ίʔσΟϯά୲ͷͻͱʹLaravelΛଟগ͕ΜͬͯΒ͏ඞཁ͕͋Δ w Ͱͦͷޙͷमਖ਼ͱ͔͍͢͠ͷͰ w Γ୭ͷڥͰಈ͘։ൃڥis preciousʜ
ͨͱ͑LaravelͳΒ w ڥมͰproductionҎ֎ ͷͱ͖ʹಈ͘ϞοΫ༻ͷϧʔ τΛ࡞͓ͬͯ͘ w ˠDocRootΓସ͑ͳ͘ ͍͍ͯʂ w ˠgulpͱ͔Θͣʹ
laravel-mix͚ͩͰ͍͍ʁ
ͱ͜ΖͰͲ͏͍͏ ۀͯ͠·͔͢
w σβΠφʔϚʔΫΞοϓ͢Δʁ͠ͳ͍ʁ w ϑϩϯτΤϯυΤϯδχΞViewͷΈࠐΈ͢Δʁ͠ͳ͍ʁ w όοΫΤϯυΤϯδχΞCSS৮Δʁ৮Βͳ͍ʁʢ৮Γͨ͘ͳ͍ʁʣ w ͦͦϑϩϯτΤϯυͱ͔όοΫΤϯυͱ͔͠ΌΒͤ͑͘ʁ ΦϨ͕શ෦ͬͯΔͥʁ
41"ͩͬͨΒʁ w ݸਓతʹ࠷ॳ͔ΒΨϦΨϦॻ͍ͨ΄͏ָ͕ w ͱ͍͑ɺ͢Ͱʹͬͨ͜ͱ͕͋Δ͔Βͳͷ͔ w σβΠφʔ͞Μ͕ίʔυॻ͘ͳΒ࡞Δ͔͠Εͳ͍ʜʜʁ
ͬ͘͟Γ·ͱΊΔͱ w ΞϓϦέʔγϣϯͷςϯϓϨʔτΛ࡞Δͱ͖ʹϞοΫΞοϓͭ͘ΔલఏͰ w ϞοΫΞοϓΛ͍ͭ·Ͱอ࣋͢Δͷ͔֬ೝ w σβΠϯΧϯϓϓϩτλΠϓߋ৽͞ΕΔͷ͔֬ೝ w ୭ͰݟΒΕΔঢ়ଶʹ͓͖͔ͯ֬͘͠ೝ w
ΞϓϦέʔγϣϯͷςϯϓϨʔτΤϯδϯΛ͏΄͏ָ͕ w ίʔυϕʔεΛ͚ͯϑΝΠϧΛίϐʔ͢ΔͷࣄނΓ͍͢ͷͰΊΑ͏
ϞοΫΞοϓΛ࡞Δత w ϞοΫαʔόͷΑ͏ʹɺͰ͖ͯͳ͍ͱ͜ΖΛସ͢Δ w ઌʹਫ਼៛ͳͷΛ࡞ͬͯΫϦΤΠςΟϒͷίϛϡχέʔγϣϯΛ׆ൃԽ͞ ͤΔ w ͘͠ɺσβΠϯҰཡͷସ w ۀ͢ΔͨΊʹͰ͖Δͱ͜Ζ·ͰͬͯΒ͏
ελΠϧΨΠυͷͱ͔ ฉ͖͍ͨͷͰͥͻ#03ͰͬͯΔͥʂʂʂ
͋Γ͕ͱ͏͍͟͝·ͨ͠