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

🐛 [Bug]: Uploader React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports. #710

Open
1 of 2 tasks
yaodongyi opened this issue Mar 21, 2024 · 4 comments

Comments

@yaodongyi
Copy link

Which React Vant packages are impacted?

  • react-vant (React Vant core)
  • react-vant-icons(React Vant Icon)

What version of React Vant are you using?

"react-vant": "^3.3.1"

Reproduce live demo(codesandebox or stackblitz)?

No response

Descripition

<Uploader
      accept="*"
      defaultValue={[
        {
          url: 'https://img.yzcdn.cn/vant/sand.jpg', // 图片文件
        },
      ]}
      onChange={v => console.log(v)}
    />
image
@3lang3
Copy link
Owner

3lang3 commented Mar 24, 2024

无法复现,确认是不是项目配置问题

@yaodongyi
Copy link
Author

无法复现,确认是不是项目配置问题

    "react-vant": "^3.3.4"
import { Button, Cell, Input, Radio, Switch } from 'react-vant'

  <Radio.Group defaultValue="1">
    <Radio name="1">单选框1</Radio>
    <Radio name="2">单选框2</Radio>
  </Radio.Group>

这里很多组件都出现该问题,今天使用radio也是这样,版本3.3.4,是需要增加哪些配置才能正常使用呢?
image

@yaodongyi
Copy link
Author

image

@yaodongyi
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