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

onClickOutside: Argument of type 'Ref<null>' is not assignable to parameter of type 'MaybeElementRef'. #405

Closed
productdevbook opened this issue Mar 30, 2021 · 9 comments

Comments

@productdevbook
Copy link

Screen Shot 2021-03-30 at 20 28 51
iam used some [example](const target = ref(null)
onClickOutside(target, (event) => accessor.modalComponent.setQuicSearchInterfaceField({ key: 'isOpen', value: false })))

const target = ref(null)
   
 onClickOutside(target, (event) => accessor.modalComponent.setQuicSearchInterfaceField({ key: 'isOpen', value: false }))
@antfu
Copy link
Member

antfu commented Mar 31, 2021

image

Didn't see the error, what's your tsconfig.json?

@productdevbook
Copy link
Author

{
  "compilerOptions": {
    "target": "esnext",
    "module": "esnext",
    "moduleResolution": "node",
    "lib": ["esnext", "esnext.asynciterable", "dom"],
    "esModuleInterop": true,
    "experimentalDecorators": true,
    "sourceMap": true,
    "strict": true,
    "noEmit": true,
    "baseUrl": ".",
    "importsNotUsedAsValues": "preserve",
    "paths": {
      "~/*": ["./*"],
      "@/*": ["./*"]
    },
    "types": ["@types/node", "@nuxt/types", "nuxt-i18n", "nuxt-tailvue"]
  },
  "exclude": ["node_modules", ".nuxt", "dist"]
}

@antfu
Copy link
Member

antfu commented Mar 31, 2021

Doesn't find anything suspicious. Maybe updates your vue version?

@productdevbook
Copy link
Author

productdevbook commented Apr 1, 2021

Doesn't find anything suspicious. Maybe updates your vue version?

"@vue/runtime-dom": "3.0.10",
3.0.7 -> 3.0.10
update and see problem library

@productdevbook productdevbook reopened this Apr 1, 2021
@wheatjs
Copy link
Member

wheatjs commented Apr 1, 2021

@productfrontenddeveloper I'm unable to reproduce this using the latest vue version(3.0.10). Can you provide a link to a minimal reproduction repo

@sibbng
Copy link
Member

sibbng commented Apr 1, 2021

That _refBrand thing only exist in https://github.com/vuejs/composition-api/blob/master/src/reactivity/ref.ts

Seems related to changes in vuejs/composition-api#668

@wheatjs
Copy link
Member

wheatjs commented May 12, 2021

@productfrontenddeveloper is this still an issue for you?

@productdevbook
Copy link
Author

@productfrontenddeveloper is this still an issue for you?

no

@rich1e
Copy link

rich1e commented Jul 19, 2023

What is the cause of this problem? How to solve it?

image

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

No branches or pull requests

5 participants