HashLocation策略有什么缺点吗? [英] Is there any downside of HashLocation Strategy?

查看:49
本文介绍了HashLocation策略有什么缺点吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在学习Angular.我已经使用HashLocation实现了路由器,因为PathLocation在Apache服务器中不起作用.为了解决这个问题,我经历了很多篇文章,但最后必须解决Apache的HashLocation问题.

I am currently learning Angular. I have implemented routers using HashLocation, because PathLocation is not working in Apache server. I went through various posts to solve that, but in the end have to settle with HashLocation for Apache.

我只想知道HashLocation是否有缺点,例如是否有任何Angular功能不能与HashLocation一起使用,我可以将HashLocation用于生产就绪的应用程序吗?

I just want to know that if there is any downside of HashLocation, like is there any Angular feature that does not work with HashLocation and can I use HashLocation for production ready apps?

推荐答案

根据

几乎所有的Angular项目都应使用默认的HTML5样式.它产生的URL更易于用户理解.并且保留了稍后进行服务器端渲染的选项.

Almost all Angular projects should use the default HTML5 style. It produces URLs that are easier for users to understand. And it preserves the option to do server-side rendering later.

服务器端渲染使您的应用更快,更安全.

Server side rendering makes your app faster and more secure.

这篇关于HashLocation策略有什么缺点吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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