Upgrade to Pro — share decks privately, control downloads, hide ads and more …

移りゆくデファクトスタンダードにチームとしてどう追従するか

tk-masuda
October 06, 2022

 移りゆくデファクトスタンダードにチームとしてどう追従するか

DroidKaigi 2022
移りゆくデファクトスタンダードにチームとしてどう追従するか tk-masuda

tk-masuda

October 06, 2022
Tweet

Other Decks in Programming

Transcript

  1. ҠΓΏ͘σϑΝΫτελϯμʔυ
    ʹνʔϜͱͯ͠Ͳ͏௥ै͢Δ͔
    Taikai Masuda / tk-masuda
    Oisix ra daichi inc.
    Android Developer
    1

    View full-size slide

  2. ຊηογϣϯͷΰʔϧ
    σϑΝΫτελϯμʔυͱ൑அ͢Δج४ΛνʔϜͰ࣋ͯΔΑ͏ʹͳΔ
    ໨తʹର͢ΔҰͭͷखஈͱͯ͠σϑΝΫτελϯμʔυʹ௥ै͢Δબ୒Λߦ͑
    ΔΑ͏ʹͳΔ
    Ͳ͜·Ͱ௥ै͢Δ͔ͷબ୒
    ௥ै͠ͳ͍બ୒
    2

    View full-size slide

  3. Agenda
    3
    01 σϑΝΫτελϯμʔυͱ͸
    02 ͲͷΑ͏ʹ൑அ͢Δ͔
    03 ௥ै͍ͯͨ͘͠Ίʹ
    04 ࣮ମݧɺtips

    View full-size slide

  4. Agenda
    4
    01 σϑΝΫτελϯμʔυͱ͸
    02 ͲͷΑ͏ʹ൑அ͢Δ͔
    03 ௥ै͍ͯͨ͘͠Ίʹ
    04 ࣮ମݧɺtips

    View full-size slide

  5. “ެతͳඪ४ظ͔ؒΒͷೝূͰ͸ͳ͘ɺࢢ৔
    ʹ͓͚Δاۀؒͷڝ૪ʹΑͬͯɺۀքͷඪ४
    ͱͯ͠ೝΊΒΕΔΑ͏ʹͳͬͨن֨ͷ͜ͱ”
    5
    σϑΝΫτελϯμʔυ
    ΢ΟΩϖσΟΞʢWikipediaʣ:ϑϦʔඦՊࣄయ

    View full-size slide

  6. ֤༻ޠͷΠϝʔδ
    6
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  7. ֤༻ޠͷΠϝʔδ
    Ϟμϯ
    7
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  8. ֤༻ޠͷΠϝʔδ
    Ϟμϯ
    ࠷৽ٕज़͕ͩ࢖༻࣮੷͕গͳ͍
    8
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  9. ֤༻ޠͷΠϝʔδ
    Ϟμϯ
    ࠷৽ٕज़͕ͩ࢖༻࣮੷͕গͳ͍
    Experimentalͳ΋ͷͰ͸ͳ͍
    9
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  10. ֤༻ޠͷΠϝʔδ
    Ϟμϯ
    ࠷৽ٕज़͕ͩ࢖༻࣮੷͕গͳ͍
    Experimentalͳ΋ͷͰ͸ͳ͍
    Ver 1.xҎ্ͰϦϦʔε͞Ε͍ͯΔΑ͏ͳ΋ͷ
    10
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  11. ֤༻ޠͷΠϝʔδ
    Ϟμϯ
    ࠷৽ٕज़͕ͩ࢖༻࣮੷͕গͳ͍
    Experimentalͳ΋ͷͰ͸ͳ͍
    Ver 1.xҎ্ͰϦϦʔε͞Ε͍ͯΔΑ͏ͳ΋ͷ
    →ϓϩμΫτ࠾༻͕ݟૹΒΕΔ܏޲
    11
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  12. ֤༻ޠͷΠϝʔδ
    ϨΨγʔ
    12
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  13. ֤༻ޠͷΠϝʔδ
    ϨΨγʔ
    ୅ସٕज़͕͋Δ
    13
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  14. ֤༻ޠͷΠϝʔδ
    ϨΨγʔ
    ୅ସٕज़͕͋Δ
    ࢖ΘΕͳ͘ͳٕͬͨज़
    14
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  15. ֤༻ޠͷΠϝʔδ
    ϨΨγʔ
    ୅ସٕज़͕͋Δ
    ࢖ΘΕͳ͘ͳٕͬͨज़
    ߋ৽͞Εͳ͘ͳٕͬͨज़
    15
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  16. ֤༻ޠͷΠϝʔδ
    ϨΨγʔ
    ୅ସٕज़͕͋Δ
    ࢖ΘΕͳ͘ͳٕͬͨज़
    ߋ৽͞Εͳ͘ͳٕͬͨज़
    →ϓϩμΫτ࠾༻͕ݟૹΒΕΔ܏޲
    16
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  17. ֤༻ޠͷΠϝʔδ
    σϑΝΫτελϯμʔυ
    17
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  18. ֤༻ޠͷΠϝʔδ
    σϑΝΫτελϯμʔυ
    ޿͘࢖ΘΕ͍ͯΔ΋ͷ
    18
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  19. ֤༻ޠͷΠϝʔδ
    σϑΝΫτελϯμʔυ
    ޿͘࢖ΘΕ͍ͯΔ΋ͷ
    ࢖͏ʹ͋ͨͬͯݱࡏ࣌఺Ͱ՝୊ײ͕࠷΋গͳ͍΋ͷ
    19
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  20. ֤༻ޠͷΠϝʔδ
    σϑΝΫτελϯμʔυ
    ޿͘࢖ΘΕ͍ͯΔ΋ͷ
    ࢖͏ʹ͋ͨͬͯݱࡏ࣌఺Ͱ՝୊ײ͕࠷΋গͳ͍΋ͷ
    ޷ح৺͔Β͘Δ࢖ͬͯΈ͍ͨɺͰ͸ͳ͍
    20
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  21. ֤༻ޠͷΠϝʔδ
    σϑΝΫτελϯμʔυ
    ޿͘࢖ΘΕ͍ͯΔ΋ͷ
    ࢖͏ʹ͋ͨͬͯݱࡏ࣌఺Ͱ՝୊ײ͕࠷΋গͳ͍΋ͷ
    ޷ح৺͔Β͘Δ࢖ͬͯΈ͍ͨɺͰ͸ͳ͍
    →ϓϩμΫτ࠾༻͞ΕΔ܏޲
    21
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  22. 22
    Ϟμϯ
    ϨΨγʔ
    ̓
    ֤༻ޠͷΠϝʔδ
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  23. 23
    Ϟμϯ
    ϨΨγʔ
    σϑΝΫτ
    ελϯμʔυ
    ̓
    ֤༻ޠͷΠϝʔδ
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  24. 24
    Ϟμϯ
    ϨΨγʔ
    σϑΝΫτ
    ελϯμʔυ
    ̓
    ֤༻ޠͷΠϝʔδ
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  25. 25
    Ϟμϯ
    ϨΨγʔ
    σϑΝΫτ
    ελϯμʔυ
    ̓
    ֤༻ޠͷΠϝʔδ
    ϞμϯɺϨΨγʔɺσϑΝΫτελϯμʔυ

    View full-size slide

  26. “ެతͳඪ४ظ͔ؒΒͷೝূͰ͸ͳ͘ɺࢢ৔
    ʹ͓͚Δاۀؒͷڝ૪ʹΑͬͯɺۀքͷඪ४
    ͱͯ͠ೝΊΒΕΔΑ͏ʹͳͬͨن֨ͷ͜ͱ”
    26
    σϑΝΫτελϯμʔυ
    ΢ΟΩϖσΟΞʢWikipediaʣ:ϑϦʔඦՊࣄయ

    View full-size slide

  27. “ެతͳඪ४ظ͔ؒΒͷೝূͰ͸ͳ͘ɺࢢ৔
    ʹ͓͚Δاۀؒͷڝ૪ʹΑͬͯɺۀքͷඪ४
    ͱͯ͠ೝΊΒΕΔΑ͏ʹͳͬͨن֨ͷ͜ͱ”
    σϑΝΫτελϯμʔυ
    ΢ΟΩϖσΟΞʢWikipediaʣ:ϑϦʔඦՊࣄయ
    27

    View full-size slide

  28. Android։ൃͷඪ४
    28

    View full-size slide

  29. 29
    ݴޠ
    Java
    Kotlin
    https://kotlinlang.org/

    View full-size slide

  30. 30
    πʔϧ
    AndroidStudio
    Gradle

    View full-size slide

  31. 31
    ઃܭ
    MVVMɺMVPɺFluxɺRedux
    Repositoryύλʔϯ
    https://developer.android.com/topic/
    architecture/ui-layer


    https://developer.android.com/topic/
    architecture/data-layer

    View full-size slide

  32. 32
    ։ൃ؀ڥ
    CI/CD
    Linter
    Formatter

    View full-size slide

  33. 33
    ςετ
    JUnit
    Truth
    Espresso
    Robolectric
    Mockito

    View full-size slide

  34. 34
    ओཁϥΠϒϥϦ
    ௨৴
    Retrofit
    UI
    JetpackComposeɺCoil
    DI
    daggerɺKoin
    https://developer.android.com/jetpack/compose?
    hl=ja

    View full-size slide

  35. Android։ൃͷඪ४
    ݴޠ
    πʔϧ
    ઃܭ
    ։ൃ؀ڥ
    ςετ
    ओཁϥΠϒϥϦ
    35

    View full-size slide

  36. Agenda
    36
    01 σϑΝΫτελϯμʔυͱ͸
    02 ͲͷΑ͏ʹ൑அ͢Δ͔
    03 ௥ै͍ͯͨ͘͠Ίʹ
    04 ࣮ମݧɺtips

    View full-size slide

  37. σϑΝΫτελϯμʔυͷ൑அج४
    37
    Ϟμϯ
    ϨΨγʔ
    σϑΝΫτ
    ελϯμʔυ
    ̓

    View full-size slide

  38. σϑΝΫτελϯμʔυͷ൑அج४
    38
    ϞμϯˠσϑΝΫτελϯμʔυ
    Ϟμϯ
    σϑΝΫτ
    ελϯμʔυ
    ̓

    View full-size slide

  39. σϑΝΫτελϯμʔυͷ൑அج४
    39
    σϑΝΫτελϯμʔυˠϨΨγʔ
    ϨΨγʔ
    σϑΝΫτ
    ελϯμʔυ
    ̓

    View full-size slide

  40. ൑அ͢Δࡐྉ
    40

    View full-size slide

  41. 41
    χϡʔειʔε
    Android Developers Blog Japan
    Android Developers Blog

    View full-size slide

  42. 42
    χϡʔειʔε
    Android Developers Blog Japan
    Android Developers Blog
    Android Developers - Medium

    View full-size slide

  43. 43
    χϡʔειʔε
    Android Developers Blog Japan
    Android Developers Blog
    Android Developers - Medium
    PRO ANDROID DEV

    View full-size slide

  44. 44
    χϡʔειʔε
    Android Developers Blog Japan
    Android Developers Blog
    Android Developers - Medium
    PRO ANDROID DEV
    Android Dagashi

    View full-size slide

  45. 45
    ͦͷଞ
    ษڧձ
    ΧϯϑΝϨϯε

    View full-size slide

  46. 46
    ͦͷଞ
    ษڧձ
    ΧϯϑΝϨϯε
    ٕज़ॻ

    View full-size slide

  47. 47
    ͦͷଞ
    ษڧձ
    ΧϯϑΝϨϯε
    ٕज़ॻ
    པΕΔਓΛݟ͚ͭΔ
    SNS
    ٕज़ސ໰

    View full-size slide

  48. ൑அج४
    48

    View full-size slide

  49. ൑அج४
    ໌֬ͳఆྔͰ͸൑அͰ͖ͳ͍
    49

    View full-size slide

  50. ൑அج४
    ໌֬ͳఆྔͰ͸൑அͰ͖ͳ͍
    ʮ࢖ͬͯΈͨʯ͸·ͩϞμϯ
    50

    View full-size slide

  51. ൑அج४
    ໌֬ͳఆྔͰ͸൑அͰ͖ͳ͍
    ʮ࢖ͬͯΈͨʯ͸·ͩϞμϯ
    Ή͠Ζهࣄ͕ग़ͳ͘ͳ͖ͬͯͨ͋ͨΓ
    ʮ͑ʁ౰ͨΓલͩΑͶʁʯ
    51

    View full-size slide

  52. ൑அج४
    ໌֬ͳఆྔͰ͸൑அͰ͖ͳ͍
    ʮ࢖ͬͯΈͨʯ͸·ͩϞμϯ
    Ή͠Ζهࣄ͕ग़ͳ͘ͳ͖ͬͯͨ͋ͨΓ
    ʮ͑ʁ౰ͨΓલͩΑͶʁʯ
    Ԡื৚݅΍࠾༻໘઀Ͱʮxxx͸࢖͑·͔͢ʁʯͱฉ͔ΕΔΑ͏ͳ΋ͷ
    52

    View full-size slide

  53. ۃ࿦ɺओ؍
    53

    View full-size slide

  54. ൑அج४
    54
    σϑΝΫτελϯμʔυͱࢥΘΕΔྫ

    View full-size slide

  55. ൑அج४
    JetpackCompose
    55
    σϑΝΫτελϯμʔυͱࢥΘΕΔྫ
    https://developer.android.com/jetpack/compose?hl=ja

    View full-size slide

  56. ൑அج४
    Modularization
    56
    σϑΝΫτελϯμʔυͱࢥΘΕΔྫ
    https://developer.android.com/topic/modularization

    View full-size slide

  57. ൑அج४
    57
    ϞμϯͱࢥΘΕΔྫ

    View full-size slide

  58. ൑அج४
    StableͰ͸ͳ͍ϥΠϒϥϦ
    Alpha
    Beta
    RC
    58
    ϞμϯͱࢥΘΕΔྫ

    View full-size slide

  59. ൑அج४
    59
    ఆྔͰ൑அΛޡΔྫ

    View full-size slide

  60. ൑அج४
    Agera
    60
    ఆྔͰ൑அΛޡΔྫ

    View full-size slide

  61. ൑அج४
    Agera
    Star਺ଟΊ
    ౰࣌ϞμϯͰʮ࢖ͬͯΈͨʯهࣄ͕େྔ
    61
    ఆྔͰ൑அΛޡΔྫ

    View full-size slide

  62. ൑அج४
    Agera
    Star਺ଟΊ
    ౰࣌ϞμϯͰʮ࢖ͬͯΈͨʯهࣄ͕େྔ
    ϞμϯˠϨΨγʔ
    ϞμϯˠσϑΝΫτελϯμʔυʹͳΒͳ͔ͬͨྫ
    62
    ఆྔͰ൑அΛޡΔྫ

    View full-size slide

  63. Agenda
    63
    01 σϑΝΫτελϯμʔυͱ͸
    02 ͲͷΑ͏ʹ൑அ͢Δ͔
    03 ௥ै͍ͯͨ͘͠Ίʹ
    04 ࣮ମݧɺtips

    View full-size slide

  64. ඞཁੑΛߟ͑Δ
    64
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  65. ඞཁੑΛߟ͑Δ
    deprecatedʢඇਪ঑ʣ
    65
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  66. ඞཁੑΛߟ͑Δ
    deprecatedʢඇਪ঑ʣ
    ະདྷతʹ࢖͑ͳ͘ͳΔ
    66
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  67. ඞཁੑΛߟ͑Δ
    deprecatedʢඇਪ঑ʣ
    ະདྷతʹ࢖͑ͳ͘ͳΔ
    ΞοϓσʔτͰ͖ͳ͘ͳΔ
    67
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  68. ඞཁੑΛߟ͑Δ
    ՝୊ͷ์ஔ
    68
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  69. ඞཁੑΛߟ͑Δ
    ՝୊ͷ์ஔ
    ৽͍ٕ͠ज़͸ࠓ·Ͱೝ஌͞Ε͍ͯͳ͔ͬͨ՝୊Λղܾ͢Δ΋ͷͰ͋Δ͜ͱ͕
    ଟ͍
    69
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  70. ඞཁੑΛߟ͑Δ
    ՝୊ͷ์ஔ
    ৽͍ٕ͠ज़͸ࠓ·Ͱೝ஌͞Ε͍ͯͳ͔ͬͨ՝୊Λղܾ͢Δ΋ͷͰ͋Δ͜ͱ͕
    ଟ͍
    ʮ௥ै͠ͳ͍ʯͱ͍͏͜ͱ͸ɺੈؒҰൠͰ՝୊ͱ͞Ε͍ͯΔ΋ͷΛ์ஔ͢Δ
    ͜ͱʹ΄͔ͳΒͳ͍
    70
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  71. ඞཁੑΛߟ͑Δ
    ະདྷɺطଘνʔϜϝϯόʔͷϞνϕʔγϣϯ
    71
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  72. ඞཁੑΛߟ͑Δ
    ະདྷɺطଘνʔϜϝϯόʔͷϞνϕʔγϣϯ
    ࠾༻Ͱ͖ͳ͍
    72
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  73. ඞཁੑΛߟ͑Δ
    ະདྷɺطଘνʔϜϝϯόʔͷϞνϕʔγϣϯ
    ࠾༻Ͱ͖ͳ͍
    طଘϝϯόʔͷ཭୤ͷՄೳੑ
    73
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  74. ඞཁੑΛߟ͑Δ
    ະདྷɺطଘνʔϜϝϯόʔͷϞνϕʔγϣϯ
    ࠾༻Ͱ͖ͳ͍
    طଘϝϯόʔͷ཭୤ͷՄೳੑ
    ϝϯόʔ཭୤ˍ࠾༻Ͱ͖ͳ͍ͱɺɺɺ
    ࣄۀܧଓੑʹѱӨڹ
    74
    ௥ै͠ͳ͍͜ͱʹΑΔෆརӹ

    View full-size slide

  75. ඞཁੑΛߟ͑Δ
    75
    ௥ै͢Δ͜ͱʹΑΔརӹ

    View full-size slide

  76. ඞཁੑΛߟ͑Δ
    ਪ঑͞Ε͍ͯΔ࣮૷Λ࠾༻Ͱ͖Δ
    76
    ௥ै͢Δ͜ͱʹΑΔརӹ

    View full-size slide

  77. ඞཁੑΛߟ͑Δ
    ਪ঑͞Ε͍ͯΔ࣮૷Λ࠾༻Ͱ͖Δ
    ೝ஌Ͱ͖Δ՝୊͸ղܾ͞Ε͍ͯ͘
    77
    ௥ै͢Δ͜ͱʹΑΔརӹ

    View full-size slide

  78. ඞཁੑΛߟ͑Δ
    ਪ঑͞Ε͍ͯΔ࣮૷Λ࠾༻Ͱ͖Δ
    ೝ஌Ͱ͖Δ՝୊͸ղܾ͞Ε͍ͯ͘
    ݱࡏ·ͨ͸ະདྷͷϝϯόʔͷϞνϕʔγϣϯ͸อͨΕΔ
    78
    ௥ै͢Δ͜ͱʹΑΔརӹ

    View full-size slide

  79. ௥ै͠Α͏
    79

    View full-size slide

  80. ௥ै͠Α͏
    80

    View full-size slide

  81. શͯ௥ै͢΂͖ͳͷ͔ʁ
    81

    View full-size slide

  82. શͯ௥ै͢΂͖ͳͷ͔ʁ
    શͯΛ௥ै͢Δඞཁ͸ͳ͍
    82

    View full-size slide

  83. શͯ௥ै͢΂͖ͳͷ͔ʁ
    શͯΛ௥ै͢Δඞཁ͸ͳ͍
    ϓϩμΫτʹΑΔ
    83

    View full-size slide

  84. શͯ௥ै͢΂͖ͳͷ͔ʁ
    શͯΛ௥ै͢Δඞཁ͸ͳ͍
    ϓϩμΫτʹΑΔ
    ՝୊͕֘౰͠ͳ͍ͱ͖
    84

    View full-size slide

  85. શͯ௥ै͢΂͖ͳͷ͔ʁ
    શͯΛ௥ै͢Δඞཁ͸ͳ͍
    ϓϩμΫτʹΑΔ
    ՝୊͕֘౰͠ͳ͍ͱ͖
    ՝୊͕ແࢹͰ͖Δ΄Ͳখ͍࣌͞
    85

    View full-size slide

  86. શͯ௥ै͢΂͖ͳͷ͔ʁ
    શͯΛ௥ै͢Δඞཁ͸ͳ͍
    ϓϩμΫτʹΑΔ
    ՝୊͕֘౰͠ͳ͍ͱ͖
    ՝୊͕ແࢹͰ͖Δ΄Ͳখ͍࣌͞
    ༏ઌॱҐ͕௿͍ͱ͖
    86

    View full-size slide

  87. શͯ௥ै͢΂͖ͳͷ͔ʁ
    87
    ௥ै͠ͳ͍ྫ

    View full-size slide

  88. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Modularization
    88
    ௥ै͠ͳ͍ྫ

    View full-size slide

  89. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Modularization
    ػೳ͕ͻͱ͔ͭ͠ͳ͍Α͏ͳͱͯ΋γϯϓϧͳΞϓϦ
    Layered Architectureͷ࿩Ͱ͸ͳ͘ɺίϯςΩετ෼ׂͷ࿩
    89
    ௥ै͠ͳ͍ྫ

    View full-size slide

  90. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Room
    90
    ௥ै͠ͳ͍ྫ

    View full-size slide

  91. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Room
    ͦ΋ͦ΋ϩʔΧϧDB͕ඞཁ͔
    91
    ௥ै͠ͳ͍ྫ

    View full-size slide

  92. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Room
    ͦ΋ͦ΋ϩʔΧϧDB͕ඞཁ͔
    ϑΝΠϧอଘ
    SharedPreferences
    92
    ௥ै͠ͳ͍ྫ

    View full-size slide

  93. શͯ௥ै͢΂͖ͳͷ͔ʁ
    Room
    ͦ΋ͦ΋ϩʔΧϧDB͕ඞཁ͔
    ϑΝΠϧอଘ
    SharedPreferences
    ௥ैͨ݁͠Ռɺmigration࣌ʹ࡞ۀྔ૿େͷݒ೦
    93
    ௥ै͠ͳ͍ྫ

    View full-size slide

  94. ͲΕʹ௥ै͢Δ͔
    94

    View full-size slide

  95. ͲΕʹ௥ै͢Δ͔
    ՝୊ղܾͷखஈͱͯ͠࠾༻͢Δ
    95

    View full-size slide

  96. ͲΕʹ௥ै͢Δ͔
    ՝୊ղܾͷखஈͱͯ͠࠾༻͢Δ
    ՝୊ೝࣝͷҰக͕ෆՄܽ
    96

    View full-size slide

  97. ͲΕʹ௥ै͢Δ͔
    ՝୊ղܾͷखஈͱͯ͠࠾༻͢Δ
    ՝୊ೝࣝͷҰக͕ෆՄܽ
    νʔϜ಺Ͱͷ߹ҙ
    97

    View full-size slide

  98. ͲΕʹ௥ै͢Δ͔
    ՝୊ղܾͷखஈͱͯ͠࠾༻͢Δ
    ՝୊ೝࣝͷҰக͕ෆՄܽ
    νʔϜ಺Ͱͷ߹ҙ
    ΧʔΰɾΧϧτɾϓϩάϥϛϯά͸΍ΊΑ͏
    98

    View full-size slide

  99. ͲΕʹ௥ै͢Δ͔
    99
    ΧʔΰɾΧϧτɾϓϩάϥϛϯάʁ

    View full-size slide

  100. ͲΕʹ௥ै͢Δ͔
    ࣮ࡍʹඞཁͰ͸ͳ͍΋ͷΛϓϩάϥϛϯά͢Δ͜ͱ
    100
    ΧʔΰɾΧϧτɾϓϩάϥϛϯάʁ

    View full-size slide

  101. ͲΕʹ௥ै͢Δ͔
    ࣮ࡍʹඞཁͰ͸ͳ͍΋ͷΛϓϩάϥϛϯά͢Δ͜ͱ
    ෺ࣄΛཧղ͍ͯ͠ͳ͍৔߹ʹى͜Γ͕ͪ
    ໨త
    खஈ
    101
    ΧʔΰɾΧϧτɾϓϩάϥϛϯάʁ

    View full-size slide

  102. ͲΕʹ௥ै͢Δ͔
    ࣮ࡍʹ͸ඞཁͳ΋ͷͰ͸ͳ͍΋ͷΛϓϩάϥϛϯά͢Δ͜ͱ
    ෺ࣄΛཧղ͍ͯ͠ͳ͍৔߹ʹى͜Γ͕ͪ
    ໨త
    खஈ
    ΍ΊΑ͏
    102
    ΧʔΰɾΧϧτɾϓϩάϥϛϯάʁ

    View full-size slide

  103. ௥ै͢Δྫ
    103

    View full-size slide

  104. ͲΕʹ௥ै͢Δ͔
    104
    Architecture

    View full-size slide

  105. ͲΕʹ௥ै͢Δ͔
    ઃܭͱݴ͑ΔΑ͏ͳ΋ͷ͕ͳ͘ɺUIૢ࡞΍ϩδοΫ͕ͻͱ·ͱ·Γʹࠞࡏ
    105
    Architecture

    View full-size slide

  106. ͲΕʹ௥ै͢Δ͔
    ઃܭͱݴ͑ΔΑ͏ͳ΋ͷ͕ͳ͘ɺUIૢ࡞΍ϩδοΫ͕ͻͱ·ͱ·Γʹࠞࡏ
    SRPݪଇɺDRYݪଇͷҧ൓
    มߋ࣌ͷӨڹൣғ͕޿͍
    106
    Architecture

    View full-size slide

  107. ͲΕʹ௥ै͢Δ͔
    ઃܭͱݴ͑ΔΑ͏ͳ΋ͷ͕ͳ͘ɺUIૢ࡞΍ϩδοΫ͕ͻͱ·ͱ·Γʹࠞࡏ
    SRPݪଇɺDRYݪଇͷҧ൓
    มߋ࣌ͷӨڹൣғ͕޿͍
    ࠓޙ΋֘౰ϑΝΠϧͷมߋՄೳੑ͕ߴ͍
    107
    Architecture

    View full-size slide

  108. ͲΕʹ௥ै͢Δ͔
    108
    Modularization

    View full-size slide

  109. ͲΕʹ௥ै͢Δ͔
    ಉҰϞδϡʔϧ಺Ͱෳ਺ίϯςΩετ͕ࠞࡏ͢Δ
    109
    Modularization

    View full-size slide

  110. ͲΕʹ௥ै͢Δ͔
    ಉҰϞδϡʔϧ಺Ͱෳ਺ίϯςΩετ͕ࠞࡏ͢Δ
    SRPݪଇҧ൓
    110
    Modularization

    View full-size slide

  111. ͲΕʹ௥ै͢Δ͔
    ಉҰϞδϡʔϧ಺Ͱෳ਺ίϯςΩετ͕ࠞࡏ͢Δ
    SRPݪଇҧ൓
    υϝΠϯ෼ׂ
    111
    Modularization

    View full-size slide

  112. ͲΕʹ௥ै͢Δ͔
    ಉҰϞδϡʔϧ಺Ͱෳ਺ίϯςΩετ͕ࠞࡏ͢Δ
    SRPݪଇҧ൓
    υϝΠϯ෼ׂ
    ϨΠϠʔ෼ׂ
    112
    Modularization

    View full-size slide

  113. ͲΕʹ௥ै͢Δ͔
    ಉҰϞδϡʔϧ಺Ͱෳ਺ίϯςΩετ͕ࠞࡏ͢Δ
    SRPݪଇҧ൓
    υϝΠϯ෼ׂ
    ϨΠϠʔ෼ׂ
    ґଘํ޲ͷڧ੍
    DIPݪଇ९क
    113
    Modularization

    View full-size slide

  114. ͲΕʹ௥ै͢Δ͔
    114
    JetpackCompose

    View full-size slide

  115. ͲΕʹ௥ै͢Δ͔
    ίϯϙʔωϯτ୯ҐͰUI͕ଘࡏͤͣ࠶ར༻ੑ͕௿͍
    Atomic Design
    115
    JetpackCompose

    View full-size slide

  116. ͲΕʹ௥ै͢Δ͔
    ίϯϙʔωϯτ୯ҐͰUI͕ଘࡏͤͣ࠶ར༻ੑ͕௿͍
    Atomic Design
    σʔλͱUIͷ݁ͼ͖͕ͭ෼͔ΓͮΒ͍
    116
    JetpackCompose

    View full-size slide

  117. ௥ै͢ΔλΠϛϯά
    117

    View full-size slide

  118. ௥ै͢ΔλΠϛϯά
    ௥ै͢΂͖͕ͩɺࠓ͙࣮͢ߦʹҠͤͳ͍͜ͱ΋͋Δ
    118

    View full-size slide

  119. ௥ै͢ΔλΠϛϯά
    ௥ै͢΂͖͕ͩɺࠓ͙࣮͢ߦʹҠͤͳ͍͜ͱ΋͋Δ
    ίετɾϦεΫɾϦλʔϯͷόϥϯε
    ࡞ۀྔ
    Өڹൣғ
    ະདྷతͳίετͱϦεΫͷ௿ݮ
    119

    View full-size slide

  120. ௥ै͢ΔλΠϛϯά
    120
    Coroutine

    View full-size slide

  121. ௥ै͢ΔλΠϛϯά
    RxJava͔Βͷஔ͖׵͑
    121
    Coroutine

    View full-size slide

  122. ௥ै͢ΔλΠϛϯά
    RxJava͔Βͷஔ͖׵͑
    ࣮ࢪͷࡍ͸Ϟδϡʔϧ୯Ґ૝ఆ
    શମͷ૯ίετͱ௥ैͨ݁͠ՌͷϦλʔϯΛൺֱ
    122
    Coroutine

    View full-size slide

  123. Ϟμϯ࠾༻ͷੋඇ
    124

    View full-size slide

  124. Ϟμϯ࠾༻ͷੋඇ
    ʮϞμϯٕज़Λ࠾༻ͯ͠͸ବ໨ʯͱ͍͏Θ͚Ͱ͸ͳ͍
    Өڹ౓ͷখ͍͞Ϟδϡʔϧ΍ίʔυͰ࠾༻͢Δͷ͸ΞϦ
    125

    View full-size slide

  125. Agenda
    126
    01 σϑΝΫτελϯμʔυͱ͸
    02 ͲͷΑ͏ʹ൑அ͢Δ͔
    03 ௥ै͍ͯͨ͘͠Ίʹ
    04 ࣮ମݧɺtips

    View full-size slide

  126. ฐࣾͷ๊͍͑ͯͨ՝୊
    Կ΋͔΋Fat
    ίϯςΩετࠞࡏ
    ϨΠϠʔͰ෼͚Δ΂͖ϩδοΫࠞࡏ
    σʔλϑϩʔઓུ͕ᐆດ
    ςελϏϦςΟ͕௿͍
    127

    View full-size slide

  127. ߟ͑ΒΕͨखஈ
    Layered Architecture
    MVVM
    Modularization
    128

    View full-size slide

  128. 129
    ๊͍͑ͯͨ՝୊
    Կ΋͔΋Fat
    ίϯςΩετ
    ෼͚Δ΂͖੹຿
    σʔλϑϩʔઓུ͕ᐆດ
    ςελϏϦςΟ͕௿͍
    ߟ͑ΒΕͨखஈ
    ✓ Layered Architecture
    ✓ MVVM
    ✓ Modularization

    View full-size slide

  129. 130
    ๊͍͑ͯͨ՝୊
    Կ΋͔΋Fat
    ίϯςΩετ
    ෼͚Δ΂͖੹຿
    σʔλϑϩʔઓུ͕ᐆດ
    ςελϏϦςΟ͕௿͍
    ߟ͑ΒΕͨखஈ
    ✓ Layered Architecture
    ✓ MVVM
    ✓ Modularization

    View full-size slide

  130. 131
    ๊͍͑ͯͨ՝୊
    Կ΋͔΋Fat
    ίϯςΩετ
    ෼͚Δ΂͖੹຿
    σʔλϑϩʔઓུ͕ᐆດ
    ςελϏϦςΟ͕௿͍
    ߟ͑ΒΕͨखஈ
    ✓ Layered Architecture
    ✓ MVVM
    ✓ Modularization

    View full-size slide

  131. 132
    ๊͍͑ͯͨ՝୊
    Կ΋͔΋Fat
    ίϯςΩετ
    ෼͚Δ΂͖੹຿
    σʔλϑϩʔઓུ͕ᐆດ
    ςελϏϦςΟ͕௿͍
    ߟ͑ΒΕͨखஈ
    ✓ Layered Architecture
    ✓ MVVM
    ✓ Modularization

    View full-size slide

  132. ؾΛ͚ͭΔ΂͖͜ͱ
    খ͍͞ͱ͜Ζ͔Β΍Δ
    Өڹ౓
    ϦεΫ
    ՝୊͸ಛఆͷखஈͷΈͰ͸ղܾ͠ͳ͍
    खஈA͚ͩͰղܾ͠ͳ͍ɺɺɺ
    खஈAͱखஈBͷ྆ํͰΑ͏΍͘ղܾ
    133

    View full-size slide

  133. 134
    खॱ1
    υϝΠϯϞσϦϯά
    ঎඼
    ͓ؾʹೖΓ
    ஫จཤྺ
    Ϣʔβʔ

    View full-size slide

  134. 135
    खॱ1
    υϝΠϯϞσϦϯά
    ӨڹൣғΛߟྀͨ͠ର৅Λܾఆ
    ίετ
    ϦεΫ
    ঎඼
    ͓ؾʹೖΓ
    ஫จཤྺ
    Ϣʔβʔ

    View full-size slide

  135. 136
    खॱ1
    υϝΠϯϞσϦϯά
    ӨڹൣғΛߟྀͨ͠ର৅Λܾఆ
    ίετ
    ϦεΫ
    ʮྑ͍ίʔυʯͷݴޠԽ
    SOLIDݪଇͳͲ
    ঎඼
    ͓ؾʹೖΓ
    ஫จཤྺ
    Ϣʔβʔ

    View full-size slide

  136. 137
    खॱ2
    υϝΠϯϩδοΫͷ੾Γग़͠

    View full-size slide

  137. 138
    खॱ2
    υϝΠϯϩδοΫͷ੾Γग़͠
    Layered Architecture
    UI͸ͦͷ··

    View full-size slide

  138. 139
    खॱ2
    υϝΠϯϩδοΫͷ੾Γग़͠
    Layered Architecture
    UI͸ͦͷ··
    ॱ൪
    DomainɺInfraɺUseCaseɺ
    UI(Host Service)

    View full-size slide

  139. 140
    खॱ2
    υϝΠϯϩδοΫͷ੾Γग़͠
    Layered Architecture
    UI͸ͦͷ··
    ॱ൪
    DomainɺInfraɺUseCaseɺ
    UI(Host Service)

    View full-size slide

  140. 141
    खॱ3
    UI૚ͷϦϑΝΫλϦϯά

    View full-size slide

  141. 142
    खॱ3
    UI૚ͷϦϑΝΫλϦϯά
    MVVM
    JetpackCompose

    View full-size slide

  142. 143
    खॱ3
    UI૚ͷϦϑΝΫλϦϯά
    MVVM
    JetpackCompose

    View full-size slide

  143. ͦͷଞtips
    Google Codelabs࠷ڧ
    େ·͔ͳ֓ཁͱ΍ΓํΛֶͿ
    طଘϓϩδΣΫτΛϛχϚϜʹ࡟ͬͨαϯϓϧϓϩδΣΫτ͕͋Δͱศར
    UI͸ൺֱత࠷ޙʹɺJetpackCompose͸ཁૉٴͼϩδοΫ͕࠷খͳ΋ͷ͔Β
    σβΠϯΨΠυϥΠϯࡦఆ͢Δͱ໾ཱͭ
    144

    View full-size slide

  144. ·ͱΊ
    σϑΝΫτελϯμʔυ͸՝୊Λղܾ͢ΔखஈͰ͋Δ
    νʔϜ๊͕͑Δ՝୊Λ໌֬ʹ͢Δ
    खஈΛ஌Βͳ͍ͱ՝୊ʹؾ͚ͮͳ͍͜ͱ͕͋ΔͷͰΩϟονΞοϓ͸େࣄ
    ΧʔΰɾΧϧτɾϓϩάϥϛϯά͸΍ΊΑ͏
    145

    View full-size slide

  145. ͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝
    ·ͨ͠ʂ
    Taikai Masuda / tk-masuda
    Oisix ra daichi inc.
    Android Developer
    146
    ΧδϡΞϧ໘ஊੋඇʹʂ

    View full-size slide