Skip to content

TextareaElement lags on typing #440

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

Open
homli-admin opened this issue Apr 23, 2025 · 2 comments
Open

TextareaElement lags on typing #440

homli-admin opened this issue Apr 23, 2025 · 2 comments

Comments

@homli-admin
Copy link

homli-admin commented Apr 23, 2025

Environment

Vueform: ^1.10.6

Browser: Chrome (latest)

Vue version: 3.3.9

Vite version: 5.0.2

Reproduction

Use Vueform version ^1.10.6

Create a form with a large number of fields (especially dynamic or conditional ones)

Include at least one TextareaElement

Open the form in Chrome

Start typing in the textarea

Observe lag and performance warning in the console

Describe the bug

I’m using Vueform version ^1.10.6, and I'm noticing occasional input lag in the TextareaElement component. Sometimes, when typing into a textarea, especially in forms with many fields, there is a noticeable delay in input response. Chrome DevTools also displays a warning: 'input' handler took 756ms. If I create a custom element with a native html textarea there is no lag.

Possible Cause

Synchronous field-level validations may be triggered too frequently (e.g., on every keystroke), and the cumulative cost in large forms could be high.

@homli-admin
Copy link
Author

homli-admin commented Apr 30, 2025

I found out that autogrow='true' creates a huge lag on typing, probably caused by the watcher (in the src/composables/elements/useAutogrow.js) of the element value

@dan-dazlab
Copy link

I had this too, but for builder.
When I ran it Vueform Builder in iFrame completely isolated it works significantly faster.
BTW I have not found the real issue but all followed to autosize lib

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy