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

Xamarin.Forms Hot Reload のススメ

amay077
August 31, 2019

Xamarin.Forms Hot Reload のススメ

amay077

August 31, 2019
Tweet

More Decks by amay077

Other Decks in Programming

Transcript

  1. Xamarin.Forms Hot Reload ͷεεϝ 2019.8.31 JXUG @amay077

  2. About me • Ԟࢁ ༟ਈ - @amay077ʢ͋Ί͍ʣ • Android, iOS,

    Xamarin, TypeScript AWS, Azure… • Ѫ஌ݝࡏॅͷϑϧϦϞʔτϫʔΧʔ • ஍ཧ৘ใγεςϜɺҐஔ৘ใϓϩάϥϛϯά • DroidKaigi2017ొஃˠٕज़ॻయ2→঎ۀຊԽ(ڞஶ)  
  3. ࠓ೔͓͸ͳ͢͠Δ͜ͱ Xamarin.Forms UI։ൃπʔϧͷྺ࢙ Official ͳ Hot Reload ͕Ωλʂ Xamarin.Forms Ͱ

    Hot Reload Ͱ͖Δπʔϧ͍Ζ ͍Ζ Any Platform ࣌୅ͷը໘։ൃ  
  4. Xamarin.Forms UI։ൃπʔϧͷྺ࢙ Xamarin | Forms | XAML | Live |

    Player | Viewer | Previewer ଟ͗͢໰୊
  5. Xamarin.Forms 1.xʙ2.x ϓϨϏϡʔΞ΋σβΠφ΋Կ΋ͳ͔ͬͨ… ͨͩ໧ͬͯRun&Watch  

  6. XAML Previewer | Viewer (Xamarin.Forms Previewer) ొ৔: 2016೥4݄ࠒ ʙ ݱଘ

    هड़ͨ͠XAMLίʔυΛVisual StudioͰϓϨϏϡʔදࣔ͢Δػೳ ݱࡏ͸ Visual Studio ͷ XAMLΛ։͍ͨը໘ʹ౷߹ ػೳ໊ͷ༳Ε͕ώυ͍w (ࢲݟ)͙Δ͙Δ͕ফ͑ͳ͔ͬͨΓਅͬനͩͬͨΓΤϥʔ͕ग़ͨ Γɺ໾ʹཱͬͨهԱ͕ͳ͍ ࠷ۙͰ͸ʮσβΠϯλΠϜσʔλʯʹ΋ରԠͯ͠Δͦ͏Ͱ͢  
  7. Xamarin Live Player ొ৔: 2017೥5݄ࠒ ʙ 2018೥8݄ࠒ Mac͕ͳ͘ͱ΋iOSσόΠε΁։ൃதͷΞϓϦ͕సૹɾ ։ൃͰ͖Δͱ͞Ε͕࣮ͨࡍ͸੍໿͕ଟ͘… ࣮ଶ͸C#ΠϯλϓϦλΛ౥ࡌͨ͠ΞϓϦ

    AppStore͔ΒBAN͞ΕɺTestFlightͰͷެ։΋ఀࢭ͞Ε ࣄ্࣮ऴྃ  
  8. Xamarin Live Reload ొ৔: 2018೥4݄ࠒ ʙ 2018೥10݄ࠒ XAMLͷมߋΛΞϓϦʹసૹ͠ɺଈ࣌ʹ࣮ࡍͷΞϓϦʹద༻͢Δ ͍ΘΏΔʮHot Reloadʯػೳ

    ϓϨϏϡʔ൛ͷ··ఀ଺͠ɺVS for Mac ʹ͸ఏڙ͢Β͞Εͣ։ ൃऴྃ (ࢲݟ)ಉ࣌ظʹLive Player΋ऴྃ͠Web΍FlutterͰ͸ओྲྀͰ͋Δ ʮϥΠϒ։ൃʯ΁ͷಓ͕ด͟͞Εͨͱͯ͠େ͍ʹࣦ๬  
  9. ʮLive Reload ͸ࢮΜͩͱݴͬͨͳɺ ΞϨ͸΢ιͩʯ

  10. Live Reload վΊ XAML Hot Reload for Xamarin.Forms ొ৔ ※Live

    Reload ͱͷؔ࿈͸֬ೝͰ͖·ͤΜ
  11. None
  12. XAML Hot Reload for Xamarin.Forms 2019೥಺ϦϦʔε༧ఆ(ݱࡏ͸ϓϨϏϡʔ൛) Visual Studio 2019 /

    Visual Studio for Mac ૒ํͰར༻ Մೳ ௥Ճͷ Add-in ΍ nuget ύοέʔδෆཁ ͨͩ͠ nuget Xamarin.Forms 4.1.0.581475 Ҏ্͕ඞཁ ਖ਼ࣜϦϦʔε͞ΕΔ·ͰؾΛൈ͘ͳʂ  
  13. DEMO

  14. HotReload for XF Ҏ֎ͷબ୒ࢶ (ͱ͍͏͔ઌۦ͚)

  15. LiveXAML http://www.livexaml.com/ IDEʹAddinɺΞϓϦʹLiveXAML.dll ͕ඞཁ $240/∞ ݹ͍ Xamarin.Forms Ͱ΋ಈ͘(3.x Ͱ֬ೝ) UWP

    ʹ΋ରԠ ෳ਺σόΠεಉ࣮࣌ߦՄೳ  
  16. AndreiMisiukevich/HotReload https://github.com/AndreiMisiukevich/ HotReload VS for Win/Mac, Rider, VSCode ͳͲͰ΋࢖͑Δ C#

    ίʔυมߋͷHot Reload΋Մೳ(࣮ػͰ͸ෆ Մ)  
  17. LiveSharp https://github.com/OYIon/LiveSharp LiveXAML ͱಉ͡ਓ(νʔϜ?)͕࡞ͬͯΔ C# ίʔυมߋͷHot Reload͕Մೳ  

  18. pranshu-aggarwal/HotReloading https://github.com/pranshu-aggarwal/ HotReloading C# ίʔυมߋͷHot Reload͕Մೳ Xamarin.Forms ͷ৔߹ 3.4.0Ҏ্͕ඞཁ 

    
  19. Any Platform ࣌୅ͷը໘։ൃ for MS Developers

  20. UIΤσΟλ΍ϓϨϏϡʔΞͷݶք ʮ࣮ࡍʹಈ͍͍ͯΔΞϓϦʯͰ͸ͳ͍ ࣮ߦ؀ڥ΋։ൃ؀ڥ΋WinͳΒ·ͩ࠶ݱੑ͸ߴ͔ͬͨ iPhoneΞϓϦͷݟͨ໨ΛWindows্Ͱ࠶ݱ͢ΔͷʹϜϦ͕ ͋Δͷ͸໌ന ಛʹϓϥοτϑΥʔϜґଘͷϥΠϒϥϦΛ࢖͍ͬͯΔ৔߹ ͸ඳը͸ෆՄ ੿࡞ Xamarin.Forms.GoogleMaps ͸ͦͷҰྫ

     
  21. ͦ͜Ͱ Hot Reload Ͱ͢Α ʮ࣮ࡍʹಈ͍͍ͯΔΞϓϦʯͰ֬ೝͰ͖Δ ތுͳ͠ʹʮ࠶ݱ཰100%ʯ ݸਓతʹ͸ XAML Previewer ͸શ͘࢖͍ͬͯ·ͤΜ

    Previewer ΑΓ΋ Hot Reload ʹ։ൃύϫʔ࢖ͬͯ΄ ͍͠ > Visuals Studio νʔϜ͞Μ  
  22. ·ͱΊ

  23. ·ͱΊ Any Platform࣌୅ʹ͸ Hot Reload ͕࠷ద ৽نҊ݅ʹ͸ Hot Reload for

    XFɺ
 طଘҊ݅ʹ͸ LiveXAML ΍ͦͷଞOSSπʔϧ C# ίʔυͷ HotReload πʔϧ΋ಋೖ͢Ε͹ແఢ ʮ࣮ࡍͷΞϓϦʯͰαΫαΫ֬ೝ͠ͳ͕Βը໘Λ࡞Ζ ͏ʂ  
  24. ͝ਗ਼ௌ ͋Γ͕ͱ͏͍͟͝·ͨ͠"