You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've written a note taking app using this framework, and I've stumbled on a super weird bug: everything works fine during development, but when I build the app for production (npm run build:mac and open releases/mac/Noty.app) the textarea/editor of the app loses focus as soon as something is typed, so it's unusable.
At first I thought there was a bug in my code, but then I found the "fix":
I wanted to put a debugger statement in the render method of my React app in order to check what was going on, but that didn't work on the production build, maybe it got stripped out, makes sense
I put an eval ( 'debugger' ) there instead, and that worked, but now the bug doesn't manifest itself
My guess is that in your build toolchain there's some tool making a stupid optimization of that render method or something, which it can't do in the presence of an eval call because it's not sure if that optimization is safe to make. Just a guess.
Could you please take a look at this? I've wasted a bit of sanity trying to debug this, and the "fix" I found for it is super ugly.
The text was updated successfully, but these errors were encountered:
I agree that we should set keep_fnames to true.
We don't need to save bandwidth by mangling names, and obfuscating code for "protective measures" shouldn't be the scope here..
I've written a note taking app using this framework, and I've stumbled on a super weird bug: everything works fine during development, but when I build the app for production (
npm run build:mac
and openreleases/mac/Noty.app
) the textarea/editor of the app loses focus as soon as something is typed, so it's unusable.At first I thought there was a bug in my code, but then I found the "fix":
debugger
statement in therender
method of my React app in order to check what was going on, but that didn't work on the production build, maybe it got stripped out, makes senseeval ( 'debugger' )
there instead, and that worked, but now the bug doesn't manifest itselfeval ( '' )
here fixes the problemMy guess is that in your build toolchain there's some tool making a stupid optimization of that render method or something, which it can't do in the presence of an
eval
call because it's not sure if that optimization is safe to make. Just a guess.Could you please take a look at this? I've wasted a bit of sanity trying to debug this, and the "fix" I found for it is super ugly.
The text was updated successfully, but these errors were encountered: