ASP.NET MVC中的渐进式Web应用程序实现 [英] Progressive web app implementation in ASP.NET MVC

查看:90
本文介绍了ASP.NET MVC中的渐进式Web应用程序实现的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究渐进式Web应用程序,我想知道是否有可能将该技术与现有的ASP.NET MVC Web应用程序集成.

I'm researching progressive web apps, and i was wondering if it's possible to integrate this technology with existing ASP.NET MVC web applications.

我没有找到这种集成的任何示例,只是结合了可呈现HTML(例如角度,敲除等)的javascript框架.

I don't find any example of this integration, only in combination of javascript frameworks that render HTML like angular, knockout etc.

此外,是否可以在IIS上托管渐进式Web应用程序,或者您仅限于apache Web服务器?

Also, is it possible to host a progressive web app on IIS or are you limited to an apache web server?

推荐答案

经过测试,我通过将服务工作者和清单添加到ASP.NET MVC应用程序成功实现了功能.由于视图(HTML)是在后端呈现的,因此仅可以缓存Web应用程序的静态版本.因此,最好使用angular等生成HTML.

After testing, I was successful at implementing the functionality by adding the service worker and manifest to a ASP.NET MVC application. Since the view (HTML) gets rendered in the back-end, it's only possible to cache a static version of your web application. So preferable you should use angular etc to generate your HTML.

一个渐进式Web应用程序可在IIS和Apache Web服务器上运行.

A progressive web app works on IIS and Apache web server.

这篇关于ASP.NET MVC中的渐进式Web应用程序实现的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆