同事开发webapp(图片应用)遇到一些问题,如兼容uc浏览器,那么webapp开发在业内有没有比较成功的例子?
rt.详细补充如下
1.在webapp开发中我觉得有些过于依赖js
2.响应式设计是不是华而不实,或者说不适合国情?因为我看他们pad和phone各开发了一套程序
3.我觉得程序完全是在用web的开发思路去做,因为在开发中,完全是在用js去不断的算,布局,数据等,仅仅是把web的页面小型化
4.国内错中复杂的浏览器兼容该如何做是好?
5.再补充一点,首次请求会把所有js文件存入到localstorage,以后请求的时候根据js文件的md5戳去更新ls中的文件,说是加速访问速度,但是浏览器不是都会有缓存的么,这么做的意义在哪?
以上,还请各位大人赐教。
回复内容:
1. 既然是application,必然有logic,用js也是必然。当然,遵循html声明性的文档语言的思路,理想上应该也能用声明性的应用语言——实际上是有的,如XForms,可惜随着XHTML2等系列标准的夭折,XForms变得非常小众。目前比较现实的方向是Angular和React这样的框架继续发展下去,需要写的js会相对较少。2. 没有不适合。他们选择各开发一套,也许是缺乏响应式的经验(包括产品、设计、开发可能都缺经验),也有种可能是他们的iPad/iPhone产品有比较大的差异。
3. 本来web的优势就是不管桌面或移动或什么平台,开发方式和体验都是相当一致的。
4. 多测。遇到是uc的问题就到uc的开发者社区多多吐槽——你看至少国内厂商你可以直接用中文骂他们。
5. 用localstorage这样的方案有两个优点,一个是更细粒度的控制,另一个是可以offline使用(配合application cache等)。当然如果实际上并不需要这些点,那么这种做法是不好的。
最后,不知道怎么算成功例子,反正现在所有网站特别是移动版或多或少都可视作webapp了。 说2点体会:
1.做webapp依赖js是必然的,webapp本身就算是一个逻辑复杂的程序,必然依赖js
2.用localstorage可以做到非常精确的更新,最大化减少下载流量等等,看看这个:mtjs/mt · GitHub 1.不仅仅webapp依赖js,甚至很多单页专题都依赖于js实现一些逻辑和效果。对于webapp中js的作用类似于后端项目中的java等,不存在过度依赖的问题。JS不单纯是制作网页效果的东西。
2.更多的在于设计吧,很多设计师做的设计稿很难做成响应式的...(个人意见)
3.个人以为可以算作前端主导的项目,另外现在很多公司都是前后端分离,很多事情都放在前端来处理。
4.看你们产品的数据统计,用户少的就不用管了。
5.节省流量,提高加载速度,可以参考楼上手腾的MT 前端推荐angular加响应式框架,交互上简化很多,开发难度小,one page app在国外近来也挺火的,尺寸可放在前端计算或者远端服务器计算,都有解决方案。希望对你有帮助。
PS,你说的iPhone和ipad两套方案也许是因为他们细化了各尺寸的用户体验方式或者缺乏响应式开发经验造成的。

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Why does storing data to localstorage always fail? Need specific code examples In front-end development, we often need to store data on the browser side to improve user experience and facilitate subsequent data access. Localstorage is a technology provided by HTML5 for client-side data storage. It provides a simple way to store data and maintain data persistence after the page is refreshed or closed. However, when we use localstorage for data storage, sometimes

Successors of the Redmi Note 13 series phones are expected to land in about three months. While Xiaomi hasn't said anything about the new lineup, the first few details of the Redmi Note 14 Pro have leaked. This leak comes from Digital Chat Station, a

How to set the expiration time of localstorage requires specific code examples. With the rapid development of the Internet, front-end development often requires saving data in the browser. Localstorage is a commonly used WebAPI that aims to provide a way to store data locally in the browser. However, localstorage does not provide a direct way to set the expiration time. This article will introduce how to set the expiration time of localstorage through code examples.

The Vivo Y300 Pro just got fully revealed, and it's one of the slimmest mid-range Android phones with a large battery. To be exact, the smartphone is only 7.69 mm thick but features a 6,500 mAh battery. This is the same capacity as the recently launc

This article will explain in detail about PHP calculating the MD5 hash of files. The editor thinks it is quite practical, so I share it with you as a reference. I hope you can gain something after reading this article. PHP calculates the MD5 hash of a file MD5 (MessageDigest5) is a one-way encryption algorithm that converts messages of arbitrary length into a fixed-length 128-bit hash value. It is widely used to ensure file integrity, verify data authenticity and create digital signatures. Calculating the MD5 hash of a file in PHP PHP provides multiple methods to calculate the MD5 hash of a file: Use the md5_file() function. The md5_file() function directly calculates the MD5 hash value of the file and returns a 32-character

How to recover deleted Localstorage data? Localstorage is a technology used to store data in web pages. It is widely used in various web applications to share data between multiple pages. However, sometimes we may accidentally delete data in Localstorage, which causes us trouble. So, how to recover deleted Localstorage data? Below are specific steps and code examples. Step 1: Stop writing to Loca

Steps and precautions for using localStorage to store data This article mainly introduces how to use localStorage to store data and provides relevant code examples. LocalStorage is a way of storing data in the browser that keeps the data local to the user's computer without going through a server. The following are the steps and things to pay attention to when using localStorage to store data. Step 1: Check whether the browser supports LocalStorage

HMDhasreleasedvariousdevicesoflate,includingseveralNokia-brandedfeaturephones.Forcontext,barelyamonthhasgonebysincethecompanypresentedtheNokia32102024,areincarnationoftheNokia3210tomarkits25thanniversary.Additionally
