搜索
搜索
天涯的知库
显示页面
过去修订
您的足迹:
本页面只读。您可以查看源文件,但不能更改它。如果您觉得这是系统错误,请联系管理员。
====== Angular 进阶 ====== ===== 国际化 i18n ===== [[https://v6.angular.live/guide/i18n|官方文档]] =====HTTP ===== HTTP 流式传输:[[https://mlog.club/article/5834185|使用Angular从受保护的端点流式传输视频]] ===== 搜索结果 ===== <WRAP group> <WRAP third column> perplexity.ai * [[https://www.perplexity.ai/search/c35c62df-231c-41ef-b315-207ef64fdecb?s=c|如何创建一个创建库项目]] / [[https://indepth.dev/posts/1193/create-your-standalone-angular-library-in-10-minutes|Library]] </WRAP> <WRAP third column> mail.simperator.com * [[https://mail.simperator.com/#/mailbox/1b36096360cefe38bc5928513ba62af2|动态 Dom]] </WRAP> <WRAP third column> notion.co * [[https://www.notion.so/maiernte/Angular-a4eb920b22bd4b288f41c50b981eb810?pvs=4#0db82f0007c04535a47928764de25c1f|导航退回上一级]] </WRAP> </WRAP> ===== 问题集 ===== **问题一:404报错** Angular 刷新页面的时候出现 404 错误。有两个解决方案, <color #ed1c24>方法二测试有效</color> <code | 方案一> import { LocationStrategy, HashLocationStrategy } from '@angular/common'; @NgModule({ providers: [ { provide: LocationStrategy, useClass: HashLocationStrategy } ] }) </code> <code | 方法二> imports: [RouterModule.forRoot(routes), RouterModule.forRoot(routes, {useHash: true})], </code> **问题二:运行时出错** 以下代码在 ng serve 时没有问题,但 ng build 并推送到服务器之后就出现运行时错误。 <code | download> if(options?.headers !== null){ (options?.headers as any).Authorization = `Bearer ${BaseSetting.AccessToken}` } </code> 需要更改为 <code | download> var hd:any = options?.headers hd.Authorization = `Bearer ${BaseSetting.AccessToken}` </code>
it/framework/angurlar.txt
· 最后更改: 2023-05-21 09:53 由
goldentianya
回到顶部