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
When there is a syntax error in the widget js code, Deskulpt will crash. This happens at commit 442cf1, the head commit when I submit this issue. Below is a minimal example to reproduce this bug.
constReact=window.__DESKULPT__.defaultDeps.React;// Syntax error here, misspell "const" as "conts", will crash DeskulptcontsbannerText="My Simple Banner";functionBanner(){return(<div><h1>{bannerText}</h1></div>);}exportdefault{render: ()=><Banner/>,};
And is the error message produced when Deskulpt crashes. It happens when I add this widget to the widgets folder and render. I run Deskulpt with npm run tauri dev.
error: Expected ';', '}' or <eof>
--> \\?\C:\Users\eiger\AppData\Roaming\com.tauri.deskulpt\widgets\ok-simple-banner\src\App.jsx:3:7
|
3 | conts bannerText = "My Simple Banner";
| ----- ^^^^^^^^^^
| |
| This is the expression part of an expression statement
thread 'main' panicked at src\bundler.rs:171:21:
FATAL: Failed to parse module
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[0406/173441.713:ERROR:window_impl.cc(121)] Failed to unregister class Chrome_WidgetWin_0. Error = 0
@Charlie-XIAO@ROMEEZHOU You might want to check this out since we are writing tests for bundler this week
The text was updated successfully, but these errors were encountered:
When there is a syntax error in the widget js code, Deskulpt will crash. This happens at commit 442cf1, the head commit when I submit this issue. Below is a minimal example to reproduce this bug.
And is the error message produced when Deskulpt crashes. It happens when I add this widget to the widgets folder and render. I run Deskulpt with
npm run tauri dev
.@Charlie-XIAO @ROMEEZHOU You might want to check this out since we are writing tests for bundler this week
The text was updated successfully, but these errors were encountered: