diff --git a/docs/docs/blog/mfsu-faster-than-vite.md b/docs/docs/blog/mfsu-faster-than-vite.md index 0fa93d71a3d8..b6337e1071dc 100644 --- a/docs/docs/blog/mfsu-faster-than-vite.md +++ b/docs/docs/blog/mfsu-faster-than-vite.md @@ -39,4 +39,4 @@ Umi 4 中同时支持 webpack 和 vite 两种构建方式,跑通了后,迫 图:libs example 速度对比图

-可以看到,在这几个场景下,MFSU with esbuild 数据领先。四个模式的页面打开速度差不多,所以对比数据没在图中列出,这也是让我意外的点,原以为 Vite 请求多会让页面打开速度变慢,也有可能项目还不够复杂? +可以看到,**在这几个场景下,MFSU with esbuild 数据领先。** 四个模式的页面打开速度差不多,所以对比数据没在图中列出,这也是让我意外的点,原以为 Vite 请求多会让页面打开速度变慢,也有可能项目还不够复杂? diff --git a/docs/docs/docs/api/api.md b/docs/docs/docs/api/api.md index 97033bede62f..a43c0c3f9548 100644 --- a/docs/docs/docs/api/api.md +++ b/docs/docs/docs/api/api.md @@ -74,15 +74,6 @@ createSearchParams([["foo", "1"], ["bar", "2"]]).toString() [URLSearchParams 文档](https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams/URLSearchParams) -{ -/* - -### dynamic - -TODO: SUPPORT -*/ -} - ### generatePath 使用给定的带参数的 path 和对应的 params 生成实际要访问的路由。 diff --git a/docs/docs/docs/api/config.md b/docs/docs/docs/api/config.md index cc3c2c1300de..1be5d8de4667 100644 --- a/docs/docs/docs/api/config.md +++ b/docs/docs/docs/api/config.md @@ -452,6 +452,7 @@ Warning: There are 1 unused files: :::warning{title=🚨} 1. 属性值会经过一次 `JSON.stringify` 转换。 2. key 值的替换是通过语法形式来匹配的,比如配置了 `{'a.b.c': 'abcValue'}` 是无法替换代码中的 `a.b?.c` 的 +::: 比如, @@ -884,16 +885,6 @@ import { Icon } from 'umi'; - [swc 参考](https://swc.rs/docs/configuration/minification#configuration) - [uglifyJs 参考](https://lisperator.net/uglifyjs/compress) -{ -/* -## jsMinifier (vite 构建) - -* 类型:`string` -* 默认值: - -*/ -} - ## lessLoader - 类型:`Object` diff --git a/docs/docs/docs/guides/routes.md b/docs/docs/docs/guides/routes.md index b667f4c56458..33aab16c6e26 100644 --- a/docs/docs/docs/guides/routes.md +++ b/docs/docs/docs/guides/routes.md @@ -438,7 +438,9 @@ const location = useLocation(); 推荐使用 `useLocation`, 而不是直接访问 `history.location`. 两者的区别是 `pathname` 的部分。 `history.location.pathname` 是完整的浏览器的路径名;而 `useLocation` 中返回的 `pathname` 是相对项目配置的`base`的路径。 -举例:项目如果配置 `base: '/testbase'`, 当前浏览器地址为 `https://localhost:8000/testbase/page/apple` +举例:项目如果配置 `base: '/testbase'`, + +当前浏览器地址为 `https://localhost:8000/testbase/page/apple` `history.location.pathname` 为 `/testbase/page/apple`