Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Javascript alert windows works on Mac but not on Windows #848

Closed
xudesheng opened this issue Jul 18, 2020 · 1 comment
Closed

Javascript alert windows works on Mac but not on Windows #848

xudesheng opened this issue Jul 18, 2020 · 1 comment

Comments

@xudesheng
Copy link

xudesheng commented Jul 18, 2020

Describe the bug
alert works on Mac but not on Windows after yarn tauri build

To Reproduce
Steps to reproduce the behavior:

  1. Using following code
useEffect(()=>{
        return ()=>{
            alert("Item about to be deleted!");
        }
    },[]);
  1. Before using Tauri to build, this alert works both on Windows and Mac as expected.
  2. After using Tauri to build, this alert only works on Mac but not on Windows.

Expected behavior
Expect a consistent result.

Screenshots
Screenshot can be found at: https://github.com/xudesheng/mytodo

When you click delete, you can see an alert windows pops up on Mac but not on Windows.

Mac:
https://github.com/xudesheng/mytodo/blob/master/docs/_image/2020-07-17_21-52-02.gif

Windows:
https://github.com/xudesheng/mytodo/blob/master/docs/_image/7-17-2020%209-43-32%20PM.gif

Platform and Versions (please complete the following information):

Mac:
`
[tauri]: running info

Operating System - Darwin(19.5.0) - darwin/x64

Node.js environment
Node.js - 14.4.0
tauri.js - 0.9.1

Rust environment
rustc - 1.45.0
cargo - 1.45.0
tauri-bundler - 0.8.5

Global packages
NPM - 6.14.6
yarn - 1.22.4

App directory structure
/.git
/build
/docs
/node_modules
/public
/src
/src-tauri

App
tauri.rs - 0.7.5
mode - embedded-server
build-type - bundle
CSP - default-src blob: data: filesystem: ws: http: https: 'unsafe-eval' 'unsafe-inline'
Windows - Edge
distDir - ../build
devPath - http://localhost:3000/
`

Windows:
`
[tauri]: running info

Operating System - Windows_NT(10.0.18363) - win32/x64
Microsoft Edge - 44.18362.449.0_neutral__8wekyb3d8bbwe

Node.js environment
Node.js - 12.18.2
tauri.js - 0.9.1

Rust environment
rustc - 1.45.0
cargo - 1.45.0
tauri-bundler - 0.8.5

Global packages
NPM - 6.14.5
yarn - 1.22.4

App directory structure
/.git
/build
/docs
/node_modules
/public
/src
/src-tauri

App
tauri.rs - 0.7.5
mode - embedded-server
build-type - bundle
CSP - default-src blob: data: filesystem: ws: http: https: 'unsafe-eval' 'unsafe-inline'
Windows - Edge
distDir - ../build
devPath - http://localhost:3000/
Done in 1.91s.
`
Additional context
Add any other context about the problem here.

Stack Trace

@lucasfernog
Copy link
Member

Seems like we need to create our own alert: r0x0r/pywebview@83a193c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants