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
else and following function name should be separated by a space.
Actual Behavior
else is combined with the function name.
Context
This is found in the npm history module in file history.js of the v5 beta (in the installed module; I can't find it on GitHub). As such, I cannot modify it on my own. The file looks to have been previously minimized, and is valid until Rollup is run on it in my project.
The code as it appears is as follows (edited for brevity):
if(null!=e){/* ... */}else"production"!==process.env.NODE_ENV?x(!1,"You are trying to block a POP navigation ..."):void0;elseu("POP")
My config uses @rollup/plugin-replace to replace process.env.NODE_ENV with, in this case, a non-"production" string, which then results in the following code after Rollup completes:
if(null!=e){/* ... */}elsex$2(!1,"You are trying to block a POP navigation ...");elseu("POP");
The resulting error is Uncaught SyntaxError: Unexpected token 'else', which is pointing to the else u("POP"); part of the code, since the previous else was converted to elsex$2.
The text was updated successfully, but these errors were encountered:
Expected Behavior
else
and following function name should be separated by a space.Actual Behavior
else
is combined with the function name.Context
This is found in the npm
history
module in filehistory.js
of the v5 beta (in the installed module; I can't find it on GitHub). As such, I cannot modify it on my own. The file looks to have been previously minimized, and is valid until Rollup is run on it in my project.The code as it appears is as follows (edited for brevity):
My config uses
@rollup/plugin-replace
to replaceprocess.env.NODE_ENV
with, in this case, a non-"production"
string, which then results in the following code after Rollup completes:The resulting error is
Uncaught SyntaxError: Unexpected token 'else'
, which is pointing to theelse u("POP");
part of the code, since the previouselse
was converted toelsex$2
.The text was updated successfully, but these errors were encountered: