Skip to content

Commit f5cb72d

Browse files
authored
docs: 修复按需引入组件路径的问题 (#1522)
`at-search-bar` 路径会被识别成 `search` 而不是 `search-bar`
1 parent 7091b81 commit f5cb72d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/taro-ui-docs/markdown/quickstart.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ npm i babel-plugin-import -D
7474
'import',
7575
{
7676
libraryName: 'taro-ui',
77-
customName: name => `taro-ui/lib/components/${name.split('-')[1]}`,
78-
customStyleName: name => `taro-ui/dist/style/components/${name.split('-')[1]}.scss`
77+
customName: name => `taro-ui/lib/components/${name.slice(3)}`,
78+
customStyleName: name => `taro-ui/dist/style/components/${name.slice(3)}.scss`
7979
},
8080
'taro-ui'
8181
]

0 commit comments

Comments
 (0)