Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remaxjs+ts ,使用@vant/weapp ,页面中使用组件,ts报JSX 元素类型“VtButton”不具有任何构造签名或调用签名 #3

Closed
WangXang opened this issue Mar 11, 2022 · 6 comments

Comments

@WangXang
Copy link

Remaxjs+ts ,使用@vant/weapp ,页面中使用组件,ts报JSX 元素类型“VtButton”不具有任何构造签名或调用签名

@fanhaoyuan
Copy link
Owner

@fanhaoyuan
Copy link
Owner

fanhaoyuan commented Mar 11, 2022

如果绝对路径不可以 用相对路径寻址到node_modules/react-vant-weapp-typings就可以了

@WangXang
Copy link
Author

是的添加了,依然不行:
1646988229186

@fanhaoyuan
Copy link
Owner

//使用
import VantConfigProvider from '@vant/weapp/config-provider';
//tsconfig
{
"paths": {
 "@vant/weapp/*": ["./node_modules/react-vant-weapp-typings/dist/*"],
}
}

@fanhaoyuan
Copy link
Owner

image

image

@WangXang
Copy link
Author

好的,谢谢!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants