Answer the question
In order to leave comments, you need to log in
How to get the height of an element?
There is such an input. When I receive an error from the back, I need it to increase, I implemented this method
calcPadding() {
const error = document.querySelector('.error')
this.paddingInput = this.errorText ? error.getBoundingClientRect().height + 16 : this.paddingInput
}
watch : {
errorText() {
this.calcPadding()
}
},
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question