【问题标题】:Xamarin.forms Masterpage and MVVM ConceptXamarin.forms Masterpage 和 MVVM 概念
【发布时间】:2016-05-06 18:02:41
【问题描述】:

我是 xamarin.forms 的新手,我正在开发一个多页面应用程序(Android、iOS、Windows),该应用程序在大多数页面上都有一个共同的设计。

.net 框架有母版页的概念,它是否也可以在 Xamarin.forms 中使用?

Xamarin.forms 的最佳编码风格是什么?我读过它应该是 MVVM 架构。我从未使用过 MVVM 架构。因此,如果可能的话,任何人都可以帮助我理解 Xamarin.forms 中的 MVVM。

【问题讨论】:

    标签: c# xamarin.forms


    【解决方案1】:

    MVVM 是一种 Microsoft 模式,您可以在此处查看:https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93viewmodel 或 google away。

    Xamarin Forms XAML 但与 WPF XAML 并不完全相同,因此请注意会出现差异。

    这是一篇使用 MVVM Light 通过 MVVM 模式 Xamarin Forms 应用程序的博客文章。 http://www.xamarinhelp.com/14-days-to-building-an-enterprise-quality-xamarin-forms-app/

    这是一个巨大的话题,但它会为您指明正确的方向。然后提出的任何其他问题都可以更具体一些,因为这个问题有点太宽泛了。

    【讨论】:

      【解决方案2】:

      最简单的方法,你可以使用 FreshMVVM(为 Xamarin.Forms 设计的 MVVM)

      这个框架也有masterdetailpage相关的概念

      https://github.com/rid00z/FreshMvvm

      http://www.michaelridland.com/xamarin/xamarinforms-mvvm-first-freshmvvm-application/

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2014-02-12
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2016-06-17
        相关资源
        最近更新 更多