Debugging client-side code in Eliom

I am hitting some walls in my attempts to master Eliom: I keep finding myself in situations where the project compiles, and everything seems to run OK, but the client-side code simply fails to work. Sometimes the failure is accompanied by errors I can see in the developer console of my browser, sometimes it has been accompanied by seemingly unrelated warnings during compilation (which arduous detective work finally revealed to be relevant), and sometimes it is marked by no apparent signs of error. In most cases, I’ve been able to fiddle with the code until stuff works as expected, but the amount of dives into the Eliom source code, and blind guess work, required to figure out what is going on is exhausting. Debugging the generated JS directly seems impossible, since the code is totally unreadable.

Does anyone know of any tools or strategies I can use to make these scenarios more tractable?

I’d also be interested to learn whether others experience the same difficulties, or if this may indicate a fundamental error in my approach.