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

Transformation error (Cannot read properties of undefined (reading 'type')) #234

Open
joket1999 opened this issue Oct 24, 2023 · 0 comments

Comments

@joket1999
Copy link

joket1999 commented Oct 24, 2023

报错信息:

ERR js/funcs.jsx Transformation error (Cannot read properties of undefined (reading 'type'))
TypeError: Cannot read properties of undefined (reading 'type')
    at ~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/transforms/v3-Modal-method-with-icon-to-v4.js:98:30
    at Array.find (<anonymous>)
    at NodePath.<anonymous> (~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/transforms/v3-Modal-method-with-icon-to-v4.js:96:50)
    at ~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/node_modules/jscodeshift/src/Collection.js:75:36
    at Array.forEach (<anonymous>)
    at Collection.forEach (~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/node_modules/jscodeshift/src/Collection.js:74:18)
    at NodePath.<anonymous> (~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/transforms/v3-Modal-method-with-icon-to-v4.js:84:12)
    at ~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/node_modules/jscodeshift/src/Collection.js:75:36
    at Array.forEach (<anonymous>)
    at Collection.forEach (~/.nvm/versions/node/v18.17.1/lib/node_modules/@ant-design/codemod-v4/node_modules/jscodeshift/src/Collection.js:74:18)

property.key有可能为undefined

图片

v3-Modal-method-with-icon-to-v4.js:98

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

1 participant