9

I made a web app where I can build any kind of form, with sections, validations, multiple type of inputs (even coordinates or polygons, photos, etc.) while allowing to see a preview of how that would look in a mobile app. That preview is because when you're done building the form and saved it to the DB, then in a mobile app (which I made as well) you can choose that form and use it.

Everything is beautiful, but after 3 sections with 25 questions each, everything becomes really slow because of the insane amount of actions that redux-form fires on every character type 😢

Today I made a public demonstration, and despite my code is very clean and well made, I think, that slowness made me look like a shitty developer, even thought I know what I made is like a 1000 times better than what I was asked to develop.

Comments
  • 0
    Try to run the validation on submit, it'll dramatically increase its performance.
  • 1
    You should run a debouncer on those keystrokes. It will significantly increase your performance :)
  • 1
    @barrymdoyle Debounce the validations right? I'll try that.
  • 1
    @racsoraul I meant on every key type but yeah give it a shot, I'm sure it's the easiest clean fix to your problem here :)
  • 1
    @CodinNShakin I can't do that. Multiple validations need to run on field modification to compare it with others. For instance, there are fields inside sections that represent a "variable name" for the resulting schema form, so I need to check on every keystroke if the field is unique. If I do that until the end of a big form, the user experience for fixing those names of the whole form may be no that nice.
  • 1
    @barrymdoyle Thanks! I'll try debouncing the onChange field function.
  • 1
    @racsoraul Yeah that's exactly where you need to implement it! Let me know how it goes :)
  • 3
    Definetly try debounce this could help with the speed a lot!
Add Comment