We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
hidden
1 parent 6bf1f7f commit d194ab1Copy full SHA for d194ab1
app/javascript/js/controllers/nested_form_controller.js
@@ -30,7 +30,7 @@ export default class extends NestedForm {
30
31
toggleAddButton() {
32
if (this.limitValue > 0) {
33
- this.addButtonTarget.classList.toggle('hidden', this.nestedRecordTargets.length >= this.limitValue)
+ this.addButtonTarget.hidden = this.nestedRecordTargets.length >= this.limitValue
34
}
35
36
0 commit comments