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

Vue v-for #1511

Open
qmonmert opened this issue Aug 22, 2024 · 0 comments
Open

Vue v-for #1511

qmonmert opened this issue Aug 22, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@qmonmert
Copy link

Describe the bug
Since 15.0.0 I have one test which fails on my Vue app. This test is on a specific v-for syntax.

To Reproduce
Log:

FAIL  app/admin/user-management/user-management-edit.component.spec.ts > UserManagementEdit Component > init > Should load user
TypeError: Cannot set properties of undefined (setting 'langKey')
 ❯ Proxy.createElementBlock.createElementVNode.createElementBlock.createElementVNode.createElementBlock.withDirectives.createElementVNode.onUpdate:modelValue._cache.<computed>._cache.<computed> app/admin/user-management/user-management-edit.vue:129:31
    127|             <label for="langKey" v-text="t$('userManagement.langKey')"></label>
    128|             <select class="form-control" id="langKey" name="langKey" v-model="userAccount.langKey">
    129|               <option v-for="(language, key) in languages" :value="key" :key="key">{{ language.name }}</option>
       |                               ^
    130|             </select>
    131|           </div>
 ❯ HTMLSelectElement.<anonymous> ../../../node_modules/@vue/runtime-dom/dist/runtime-dom.cjs.js:1246:20
 ❯ HTMLSelectElement.dispatchEvent ../../../node_modules/happy-dom/src/event/EventTarget.ts:222:42
 ❯ HTMLSelectElement.dispatchEvent ../../../node_modules/happy-dom/src/nodes/element/Element.ts:1224:29
 ❯ HTMLSelectElement.value ../../../node_modules/happy-dom/src/ClassMethodBinder.ts:50:50
 ❯ HTMLSelectElement.dispatchEvent ../../../node_modules/happy-dom/src/event/EventTarget.ts:131:9
 ❯ HTMLSelectElement.dispatchEvent ../../../node_modules/happy-dom/src/nodes/element/Element.ts:1224:29
 ❯ HTMLSelectElement.value ../../../node_modules/happy-dom/src/ClassMethodBinder.ts:50:50
 ❯ HTMLSelectElement.[updateSelectedness] ../../../node_modules/happy-dom/src/nodes/html-select-element/HTMLSelectElement.ts:722:9
 ❯ Proxy.value ../../../node_modules/happy-dom/src/ClassMethodBinder.ts:50:50

Do you think that it is related to this new version? 🙂 Thanks

@qmonmert qmonmert added the bug Something isn't working label Aug 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
1 participant