LiveSharp is a .NET tool that lets you develop your code without recompilation.
LiveSharp 讓你在開發 .NET 程式時不需要透過重新編譯的動作,就能看到執行結果的工具。
Read more:
了解更多:
https://github.com/OYIon/LiveSharp
This demo code is a sample/documentation to know how use LiveSharp in Xamarin.Forms.
這個 demo code 是讓你知道如何在 Xamarin.Forms 當中使用 LiveSharp 的一個展示範例/說明。
-
Install LiveSharp Visual Studio extension.
安裝 LiveSharp Visual Studio 擴充套件。 -
In Visual Studio menu: Tools > Options > (or Debug > Options) > Debugging > General, deselect "Edit and Continue" in the right pane.
在 Visual Studio 選單: 工具 > 選項 > (或 偵錯 > 選項) > 偵錯 > 一般, 在右邊窗格中取消 "啟用編輯後繼續" 的勾選。ref: How to: Enable and disable Edit and Continue (C#, VB, C++)
-
Update all Nuget packages in each project, then make sure demo code build success and work with no error.
在每一個專案當中更新所有的 Nuget 套件, 然後確認此 demo code 編譯正常成功沒有錯誤。 -
Use Debug Mode (F5) to run your App.
使用偵錯 (F5) 執行你的 App。 -
Write or Edit your C# Code in Visual Studio.
回到 Visual Studio 當中撰寫或編輯 C# Code。 -
Watch result.
觀看執行結果。
-
Create a new Xamarin.Forms project.
建立一個新的 Xamarin.Forms 的方案。 -
Update all Nuget packages in each project, then make sure your project build success and work with no error.
在每一個專案當中更新所有的 Nuget 套件, 然後確認所建立的方案編譯正常成功沒有錯誤。 -
Install LiveSharp.Support.XamarinForms Nuget package. (Just only on Xamarin.Forms Project.)
安裝 LiveSharp.Support.XamarinForms Nuget 套件。(只要在 Xamarin.Forms 專案中就好。) -
Try to build your App and make sure no error.
嘗試建置你的 App 並且確認沒有錯誤。 -
Use Debug Mode (F5) to run your App.
使用偵錯 (F5) 執行你的 App。 -
Write or Edit your C# Code in Visual Studio.
回到 Visual Studio 當中撰寫或編輯 C# Code。 -
Watch result.
觀看執行結果。