Slide 1

Slide 1 text

No content

Slide 2

Slide 2 text

H i d e t a k a O k a m o t o • Digitalcube Co. Ltd. • Nishinomiya / Kobe • WordPress 4.7 / 5.0 / 5.3 Core contributor

Slide 3

Slide 3 text

No content

Slide 4

Slide 4 text

No content

Slide 5

Slide 5 text

ͳ Μ ͷ ͨ Ί ʹ Wo rd P re s s Λ ࢖ ͬͯ ͍ · ͢ ͔ ʁ

Slide 6

Slide 6 text

Wo rd P re s s Λ ࢖ ͏ ཧ ༝ • ϒϩά΍χϡʔεαΠτɾECͳͲΛ࡞Γ͍ͨ • WebαʔϏεͷج൫ʹ͍ͨ͠ • ΤΫεςϯγϣϯൢചʢϓϥάΠϯɾςʔϚɾetcʣ • ϗεςΟϯά΍ӡ༻อकͰ঎ച͍ͨ͠ • ্࢘ɾΫϥΠΞϯτʹݴΘΕ͔ͨΒ

Slide 7

Slide 7 text

Wo rd P re s s Λ ࢖ ͏ ཧ ༝ • ൃ৴ʢPublishʣ • ։ൃʢDevelopʣ • ൢചʢSaleʣ • ӡ༻ʢMaintainʣ • ্࢘ɾΫϥΠΞϯτʹݴΘΕ͔ͨΒ

Slide 8

Slide 8 text

࣮ ࡍ ͷ ۀ ຿ • ςʔϚɾϓϥάΠϯͷ։ൃ • ίΞ ϝδϟʔΞοϓσʔτͷςετͱຊ൪൓ө • ϓϥάΠϯ / ςʔϚͷΞοϓσʔτςετͱຊ൪൓ө • PHP / MySQL / Apache / OpenSSLͳͲͷӡ༻อक • ʮͳʹ΋ͯ͠ͳ͍ͷʹյΕ·ͨ͠ʯͱ͍͏ి࿩΁ͷରԠ

Slide 9

Slide 9 text

ؾ ͕ ͭ ͚ ͹ ӡ ༻ λ ε Ϋ ͩ Β ͚

Slide 10

Slide 10 text

ͳ ʹ ͕ ͓ ͖ ͯ ͍ Δʁ • શͯͷ΋ͷ͸࣌ؒͱͱ΋ʹมԽ͢Δ • ୭͔͕౿Μͩόά΍੬ऑੑ / ෆศͳ఺Λ୭͔͕मਖ਼͍ͯ͠Δ • ʮΑΓྑ͍αΠτΛ࡞ΔͨΊʹαΠτɾهࣄΛߋ৽͢Δʯ ʹ> ʮΑΓྑ͍αΠτΛ࡞ΔͨΊʹɺΞοϓσʔτΛϦϦʔε͢Δʯ • ӡ༻ΛͪΌΜͱ·Θͤ͹ɺαΠτʢͷཪଆʣ͸ΑΓྑ͘ͳ͍ͬͯ͘

Slide 11

Slide 11 text

ͱ ͸ ͍ ͑ ɾ ɾ ɾ • Ξοϓσʔτ͸ʮ࢖ͬͨ΋ͷͷ਺ʯʹൺྫ͢Δ • αʔόʔ / ϛυϧ΢ΣΞ / CMS / ϓϥάΠϯ / ςʔϚ / npm / etc… • ੈքத͔Βू·ΔΧΠθϯΛɺςετ -> σϓϩΠ͢Δ • ΧΠθϯͷ෺ྔ࡞ઓ

Slide 12

Slide 12 text

ͭ · Δ ͱ ͜ Ζ • ӡ༻λεΫ͸ඞཁෆՄܽͱ͍͏͔ͪΌΜͱ΍Ε • ͨͩ͠࢖ͬͨ΋ͷͷ਺͚ͩλεΫྔ͕૿͍͑ͯ͘ • ʮίʔσΟϯάෆཁʯ͸ʮϝϯςෆཁʯͰ͸ͳ͍ • ʮ΍Βͳ͍ʯͰ͸ͳ͘ʮࣗ෼Ͱ΍Βͣʹࡁ·ͤΔʯ

Slide 13

Slide 13 text

΍ Γ ͨ ͍ ͜ ͱ ʹ ू த ͢ Δ ͨ Ί ʹ ͸ ɺ ʮ ࣗ ෼ Ͱ ΍ Β ͳ ͍ ͜ ͱ ʯ Λ ܾ Ί Δ

Slide 14

Slide 14 text

΍ Γ ͨ ͍ ͜ ͱ ͷ ͨ Ί ʹ ΍ Ί Δ Λ ܾ Ί Δ

Slide 15

Slide 15 text

Ξ ο ϓ σ ʔ τ ର ৅ Λ ݮ Β ͤ ͹ ӡ ༻ λ ε Ϋ ͸ ݮ Δ

Slide 16

Slide 16 text

ӡ ༻ λ ε Ϋ Λ ޮ ཰ Խ ͢ Δ ͨ Ί ʹ ߟ ͑Δ ͜ ͱ • ʮࣗ෼Ͱ΍Δʯ or ʮଞਓʹ΍ͬͯ΋Β͏ʯ or ʮࣙΊΔʯ • ࣌ؒΛ࢖͑͹ɺࣗ෼ͰͳΜͱ͔ؤுΕΔ • ͓ۚΛग़ͤ͹ɺ୭͔͕Έͯ͘ΕΔ • ػೳΛఘΊΕ͹ɺͦ΋ͦ΋ӡ༻͠ͳͯ͘ࡁΉ

Slide 17

Slide 17 text

࣌ ؒ Λ ࢖ ͑ ͹ ɺ ࣗ ෼ Ͱ Ͱ ͖ Δ • ஌ࣝΛಘΔͨΊͷ࣌ؒ΋ؚΊͯͷ࿩ • ؒҧͬͨલఏɾ஌ࣝͰͱΓ͘Ί͹ɺ΋ͪΖΜԕճΓʹͳΔ • ݕࡧɾߪೖͯ͠ಘͨ஌ࣝ͸ɺ࠷৽൛͔ʁ • ΤϥʔจͱӳޠͷݩυΩϡϝϯτ͕ಡΊΔ͔͕෼ਫྮ

Slide 18

Slide 18 text

͓ ۚ Λ ग़ ͤ ͹ ɺ ୭ ͔ ͕ Έ ͯ͘ Ε Δ • ਓΛޏ͏ɺ֎஫͢ΔɺASP / SaaSΛ࢖͏ɺ etc… • ࣗ෼Ͱ΍Βͳ͍͜ͱͰɺͦͷ෼ͷ࣌ؒΛු͔ͤΔ • Ҡৡ͢ΔͨΊͷ४උίετ͸ඞਢ • ਓʹཔΉɹɹɹɿ ϫʔΫϑϩʔͳͲͷೝࣝ߹Θͤ • αʔϏεΛ࢖͏ɿ࣮૷Λ࢓༷ʹ߹ΘͤΔ

Slide 19

Slide 19 text

ػ ೳ Λ ఘ Ί Ε ͹ ɺ ͦ ΋ ͦ ΋ ӡ ༻ ͠ ͳ ͘ ͯ ྑ ͍ • ʮͦͷػೳɺຊ౰ʹඞཁͰ͔͢ʁʯ • ͋Ε͹͍͍͸͍͍ͩͨ࢖Θͳ͍ • Only 10% of that extra stuff will ever get used, so you are wasting 90% of your time. • ޙͰ࢖͏ͩΖ͏ͱ͍͏༧ଌͷݩʹ࡞ͬͨ΋ͷ͸ɺ࣮ࡍʹ͸10%ఔ౓͔͠࢖ΘΕͳ͍ɻ
 ͕ͨͬͯ͠ɺͦΕʹඅ΍ͨ࣌ؒ͠ͷ90%͸ແବʹͳΔ • YAGNI ( You ain’t gonna need it ): ͦΜͳͷඞཁͳ͍ͬͯ

Slide 20

Slide 20 text

ʮ ͦ Ε ɺ ຊ ౰ ʹ ඞ ཁ Ͱ ͢ ͔ ʁ ʯ • ʮ͋ͬͨΒศར͡Όͳ͍ʯ -> ࣙΊΑ͏ • ʮཁ๬͸͖ͯΔʯ -> ίʔυΛॻ͔ͣʹ࣮૷ͯ͠ΈΔ • Ͳ͏ͯ͠΋ඞཁʹͳͬͨΒɺίʔυΛॻ͍࣮ͯ૷͢Δ

Slide 21

Slide 21 text

ʮ S a a S Ͱ ࢼ ͯ͠ ൓ Ԡ Λ ݟ Δ ʯ ͱ ͍ ͏ ͸ ͡ Ί ํ • ैྔ՝ۚܥSaaS͸ࣙΊ΍͘͢ɺτϥΠΞϧ͕͋Δ͜ͱ΋ଟ͍ • ґଘ͠ͳ͍Α͏ʹ૊ΈࠐΊ͹ɺ͙͢ʹࣙΊΔ͜ͱ΋Մೳ • ʮ·ͣSaaSͰࢼ͢ʯ -> ʮ෺଍Γͳ͍͔Β࡞Δʯͱ͍͏൑அ • ΍Ί΍͍͢ / ࣺͯ΍͍͔͢Βͦ͜ɺΑΓૉૣ͘มԽͰ͖Δ

Slide 22

Slide 22 text

Wo rd P re s s Λ Α Γ ศ ར ʹ ͢ Δ S a a S / F a a S ׆ ༻ ๏

Slide 23

Slide 23 text

Wo rd P re s s ʹ S a a S Λ ͭ ͔ ͏ ϝ Ϧ ο τ • WPͷίʔυྔ͕૿͑Δ = ϝϯςφϯεൣғ͕૿͑Δ • ίʔυྔͷଟ͍ϓϥάΠϯ / ςʔϚ -> Ξϓσස౓্͕ΔՄೳੑେ • SaaSͷAPIΛ࢖͏͜ͱͰɺWPͷதͷίʔυྔΛݮΒ͢ • APIͷ࢓༷͕มΘΒͳ͚Ε͹ɺWP΁ͷӨڹ͸গͳ͍ • ϝδϟʔͲ͜Ζ͸͍͍ͩͨϓϥάΠϯ͕͋Δ

Slide 24

Slide 24 text

• Χʔυ৘ใͳͲΛStripe͕؅ཧ
 WPʹػີ৘ใΛͳΔ΂࣋ͨͤ͘ͳ͍ • ఆظࢧ෷͍΍MPͳͲ΋
 APIϕʔεͰ࡞ΕΔ • ܾࡁֹʹର͢Δ੥ٻͷΈͷैྔ՝੍ۚ ܾࡁγεςϜΛSaaSར༻ʹ͢Δɿ Stripe

Slide 25

Slide 25 text

Ϣʔβʔ؅ཧɾೝূܥΛSaaSԽ͢Δɿ Auth0 • ೝূॲཧΛAuth0Ͱ؅ཧ • GoogleͳͲͷγϯάϧαΠϯΦϯ • Freeϓϥϯ͋Γͷैྔ՝੍ۚ

Slide 26

Slide 26 text

αΠτ಺ݕࡧΛSaaSԽ͢Δɿ Algoria • αΠτ಺ݕࡧΛFaaSͰ࣮૷ • શจݕࡧΛར༻ͨ͠ߴػೳͳݕࡧ • Freeϓϥϯ͋Γͷैྔ՝੍ۚ

Slide 27

Slide 27 text

AW S / G C P i s n o t “ α ʔ όʔ ԰ ͞ Μ ” • ը૾ / ςΩετ / Ի੠ೝࣝAPI • ϨίϝϯσʔγϣϯΤϯδϯ / API • ϝʔϧ / CDN / ετϨʔδ / Ωϟογϡ • ʮཉ͍͠ػೳͷAPIΛఏڙ͢ΔαʔϏεʯͱͯ͠ͷΫϥ΢υϕϯμʔ

Slide 28

Slide 28 text

Wo rd P re s s ʹ S a a S Λ ͭ ͔ ͏ σϝ Ϧ ο τ • ʮશ͕ͯࢥ͍௨Γʹ͍͘Θ͚Ͱ͸ͳ͍ʯ • SaaSଆͷ࢓༷ɾར༻੍ݶɾϓϥϯ੍ݶʹґଘ͢Δ • ഁյతมߋ͕ʮશ͘ͳ͍ʯΘ͚Ͱ͸ͳ͍ • SaaSଆͷো֐ͷר͖ఴ͑Λड͚ΔՄೳੑ • ʮαʔϏε͕ऴྃ͢Δʯͱ͍͏Մೳੑ

Slide 29

Slide 29 text

S a a S ͱ ͍ ͍ ײ ͡ ʹ ෇ ͖ ߹ ͏ • ࢼ͚ͩ͢ͳΒ͋·ΓਂೖΓ͠ͳ͍ʢࣙΊΕͳ͘ͳΔʣ • ୅ସαʔϏε͕͋Δ͔ɺWP͚ͩͰ΍Δํ๏͕͋Δ͔͸֬ೝ͢Δ • ՝ۚ͢Δ • ෍ڭͯ͠՝ۚϢʔβʔΛ૿΍͢

Slide 30

Slide 30 text

S a a S Λ ࡞ Δ ͨ Ί ʹ Wo rd P re s s Λ ར ༻ ͢ Δ

Slide 31

Slide 31 text

Wo rd P re s s ͸ Wo rd P re s s ͱ ͯ͠ ͠ ͔ ࢖ ͑ ͳ ͍ ͷ ͔ ʁ

Slide 32

Slide 32 text

G E T / w p - j s o n /

Slide 33

Slide 33 text

W P A P I ͱ ͸ • WordPressͷREST API • WordPressͷσʔλʹHTTP APIܦ༝ͰΞΫηεͰ͖Δ • Page / PostͳͲͰެ։͞Ε͍ͯΔهࣄ͸ݪଇೝূෆཁ • POST / PUT / DELETE΍ඇެ։৘ใ͸ೝূ͕ඞཁ • WordPressͷσʔλΛ֎෦͔Βѻ͏͜ͱ͕Ͱ͖Δ

Slide 34

Slide 34 text

Wo rd P re s s Λ A P I ͱ ͯ͠ ར ༻ ͢ Δ

Slide 35

Slide 35 text

Wo rd P re s s Λ A P I α ʔ όʔ ʹ ͢ Δ • HTMLͷඳըΛWordPress֎͔Βߦ͏ • jQuery / Vue / React / Angular / Ionic / EC Cube / etc… • WordPressͷςʔϚɾϓϥάΠϯʹґଘ͠ͳ͍࣮૷͕ՄೳʹͳΔ

Slide 36

Slide 36 text

ͳ ͥ Wo rd P re s s Λ A P I α ʔ όʔ ʹ ͢ Δ ͷ ͔ 1. ηΩϡϦςΟڧԽͷͨΊʹWPΛඇެ։ྖҬʹஔ͖͍ͨ 2. PWA(Progressive Web Application) / SPA(Single Page Application) 3. ViewͱAppͷαʔόʔΛ෼཭ͯ͠ෛՙΛ෼ࢄ͍ͨ͠ 4. WordPressͷ؅ཧը໘ػೳ͚ͩɺαʔϏεʹར༻͍ͨ͠ 5. etc…

Slide 37

Slide 37 text

Static Site Generator(SSG) ͰWordPressΛ࢖͏ • ϑϩϯτΤϯυք۾Ͱਓؾͷ͋ΔSSG • ࣄલʹ੩తԽͯ͠ߴ଎Խ+ෛՙ࡟ݮ • ೖߘը໘͸WordPressͷ·· • Gatsby( React )΍Nuxt( Vue ) ͳͲ • ϑϩϯτͱίϯςϯπ؅ཧͷ෼ۀԽ https://www.gatsbyjs.org/packages/gatsby-source-wordpress/

Slide 38

Slide 38 text

WordPressΛStatic Site Generatorʹ͢Δ • WordPressΛͦͷ··SSGԽ • ϑϩϯτΤϯυʹWPςʔϚ͕࢖͑Δ • LP / ίʔϙʔϨʔταΠτͳͲ޲͚ • WordPressͷ؅ཧίετΛ࡟ݮ͢Δ • ͨͩ͠ಈతग़ྗʹ͸Ұ޻෉ඞཁ https://www.getshifter.io/japanese/

Slide 39

Slide 39 text

Wo rd P re s s Λ 1 S a a S / F a a S ͱ ͯ͠ ݟ Δ • REST API͕༻ҙ͞Ε͍ͯΔ • Ϣʔβʔ΍ίϯςϯπͷ؅ཧ͕Ͱ͖ΔGUI͕͋Δ • ඞཁʹԠͯ͡ϓϥάΠϯ΍ϑοΫ(PHP)Ͱ֦ுͰ͖Δ • ʢWPͷʣϚωʔδυαʔϏε΍ӡ༻୅ߦͷબ୒ࢶ͕ଟ͍

Slide 40

Slide 40 text

ί ϯ ςϯ π ؅ ཧ ʹ ಛ Խ ͠ ͨ Wo rd P re s s ͱ ͯ͠ • ࣗࣾαʔϏεͷ͓஌Βͤ΍χϡʔεɾTipsͷ഑৴ج൫ͱͯ͠ͷWP • ձһݶఆίϯςϯπͷ഑৴ج൫ͱͯ͠ͷWP • Ϣʔβʔ౤ߘΛϨϏϡʔ -> ެ։͢ΔͨΊͷ؅ཧը໘ͱͯ͠ͷWP • ίϯςϯπ؅ཧ͚ͩʹϑΥʔΧεͯ͠΋Ϣʔεέʔε͸༷ʑ

Slide 41

Slide 41 text

C o n c l u s i o n • ӡ༻͸ͪΌΜͱ΍Ζ͏ɻͰ͖ͳ͍ͳΒ՝͔ۚσάϨ͠Α͏ • SaaS / FaaSΛ࢖͏͜ͱͰɺޮ཰తʹػೳΛ௥Ճ͠Α͏ • WP APIΛ࢖ͬͯɺWPΛ࢖ͬͨαʔϏεΛߟ͑Α͏ • WordPressΛ࢖ͬͯɺΈΜͳͰPublishing͠Α͏

Slide 42

Slide 42 text

N e e d m o re a b o u t W P + W P A P I ?

Slide 43

Slide 43 text

1 5 : 4 5 ~ R o o m A B https://2019.tokyo.wordcamp.org/session/diamond05/

Slide 44

Slide 44 text

1 2 / 7 Wo rd C a m p O s a k a 2 0 1 9 https://2019.osaka.wordcamp.org/

Slide 45

Slide 45 text

1 2 / 7 Wo rd C a m p O s a k a 2 0 1 9 https://2019.osaka.wordcamp.org/

Slide 46

Slide 46 text

#wctokyo #GetShifter https://getshifter.io/