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
import{open}from'@tauri-apps/api/dialog';asyncfunctionopenDialog(options){// Open a selection dialog for directoriesconstselected=awaitopen(options);returnselected}
But it failed to work, as custom.js is not packed by rollup, it cannot resolve import
and I run the follow command to pack it. rollup src-tauri/src/inject/custom.src.mjs --file src-tauri/src/inject/custom.x.js --format iife --watch
rollup report error
Unresolved dependencies
@tauri-apps/api/dialog (imported by "src-tauri/src/inject/custom.src.mjs")
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I want to add a function to custom.js like below
But it failed to work, as custom.js is not packed by rollup, it cannot resolve import
and I run the follow command to pack it.
rollup src-tauri/src/inject/custom.src.mjs --file src-tauri/src/inject/custom.x.js --format iife --watch
rollup report error
Beta Was this translation helpful? Give feedback.
All reactions