diff --git a/package.json b/package.json index af56370..4a394a2 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "veaury", "private": false, - "version": "2.5.0", + "version": "2.5.1", "description": "Use React in Vue3 and Vue3 in React, And as perfect as possible!", "main": "dist/veaury.umd.js", "module": "dist/veaury.esm.js", diff --git a/src/applyReactInVue.js b/src/applyReactInVue.js index 4f4ced4..5b9e838 100644 --- a/src/applyReactInVue.js +++ b/src/applyReactInVue.js @@ -659,7 +659,7 @@ export default function applyReactInVue(component, options = {}) { // Destroy the React root node if (ReactMajorVersion > 17) { - this.__veauryReactApp__.unmount() + this.__veauryReactApp__?.unmount() } else { ReactDOM.unmountComponentAtNode(this.$refs.react) } diff --git a/src/pureReactInVue/getChildInfo.js b/src/pureReactInVue/getChildInfo.js index 1dc65ba..b8650e6 100644 --- a/src/pureReactInVue/getChildInfo.js +++ b/src/pureReactInVue/getChildInfo.js @@ -45,5 +45,8 @@ export default function getChildInfo(child, index, vueInReactCall, defaultSlotsF // props.node = () => reactNode // } + // remove ref_for + if (typeof props.ref_for === "boolean") delete props.ref_for + return props }