Closed
Description
What problem does this feature solve?
Making test for components like this
<template>
<div>
<h1>Header</h1>
<button class="hidden">Test</button>
</div>
</template>
<script>
export default {
name: "Foo"
}
</script>
<style scoped>
.hidden {
display: none;
}
</style>
describe('Foo.vue', () => {
test('Button', () => {
const wrapper = shallowMount(Foo, {});
console.log(wrapper.isVisible());
const but = wrapper.find('button');
console.log(window.getComputedStyle(but.element).display);
console.log(but.isVisible());
});
});
What does the proposed API look like?
Call of isVisible will be the same as before