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

XModal throws "500 Cannot read properties of undefined (reading 'removeEventListener')" error when using Nuxt 3 SSR. #101

Open
erayturan opened this issue Dec 19, 2024 · 0 comments
Assignees

Comments

@erayturan
Copy link

erayturan commented Dec 19, 2024

Hi!

I am getting the error for the component below. When I use it in <ClientOnly>...</ClientOnly>, it does not give an error and works almost normally.

Maybe it was my mistake. I'm not sure!

Thanks

    <x-button @click="show = true">
        SHOW
    </x-button>
    <x-modal
        v-model="show"
        backdrop
        :has-actions="false"
        :has-header="false"
        show-close
        persistent
    >
        Lorem ipsum dolor sit amet consectetur, adipisicing elit. Iure
        praesentium non id dolores vitae. Nam ratione veritatis ab cumque
        voluptas porro illum, voluptate perferendis ducimus dolorem optio magni
        assumenda dolore! Doloremque facere aliquid facilis distinctio
        accusamus, dolorum eligendi consequuntur molestias sapiente non rem vero
        sed eos minus itaque sunt officiis iste ea repellendus possimus earum
        maiores? Quo laudantium fuga odit tenetur sint fugit deleniti dolores
        placeat, accusamus magni consectetur unde totam sunt labore dolor rem
        consequatur quaerat! Iure temporibus voluptatem cumque, dolore maiores
        rerum neque vero, iusto veritatis repellat eligendi amet! Molestiae
        cumque officiis eius harum iste, fuga corporis molestias.
    </x-modal>
</template>

<script setup lang="ts">
const show = ref(false)
</script>

RESPONSE

500
Cannot read properties of undefined (reading 'removeEventListener')

at checkVisibiliy (C:\dev\nuxt_prj\node_modules\@indielayer\ui\src\components\modal\Modal.js:132:9)
at callWithErrorHandling (C:\dev\nuxt_prj\node_modules\@vue\runtime-core\dist\runtime-core.cjs.js:200:19)
at callWithAsyncErrorHandling (C:\dev\nuxt_prj\node_modules\@vue\runtime-core\dist\runtime-core.cjs.js:207:17)
at baseWatchOptions.call (C:\dev\nuxt_prj\node_modules\@vue\runtime-core\dist\runtime-core.cjs.js:6136:47)
at job (C:\dev\nuxt_prj\node_modules\@vue\reactivity\dist\reactivity.cjs.js:1807:18)
at Object.watch (C:\dev\nuxt_prj\node_modules\@vue\reactivity\dist\reactivity.cjs.js:1843:7)
at doWatch (C:\dev\nuxt_prj\node_modules\@vue\runtime-core\dist\runtime-core.cjs.js:6164:34)
at Module.watch (C:\dev\nuxt_prj\node_modules\@vue\runtime-core\dist\runtime-core.cjs.js:6097:10)
at setup (C:\dev\nuxt_prj\node_modules\@indielayer\ui\src\components\modal\Modal.js:117:27)
@jpntex jpntex self-assigned this Dec 31, 2024
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