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

[bug] iframe is too many nested with isolation pattern #4015

Closed
keiya01 opened this issue Apr 30, 2022 · 3 comments
Closed

[bug] iframe is too many nested with isolation pattern #4015

keiya01 opened this issue Apr 30, 2022 · 3 comments

Comments

@keiya01
Copy link
Member

keiya01 commented Apr 30, 2022

Describe the bug

I found the iframe element is too many nested with isolation pattern.
Is this behavior expected?

Screen Shot 2022-05-01 at 0 18 16

Reproduction

  1. go to tauri repository
  2. run cargo run --example isolation --features isolation
  3. show inspector
  4. see elements tab

Expected behavior

I think we should insert the only one iframe element.

Platform and versions

Environment
  › OS: Mac OS 12.3.1 X64
  › Node.js: 16.14.0
  › npm: 8.3.1
  › pnpm: Not installed!
  › yarn: 1.22.17
  › rustup: 1.24.3
  › rustc: 1.59.0
  › cargo: 1.59.0
  › Rust toolchain: stable-aarch64-apple-darwin 

Packages
  › @tauri-apps/cli [NPM]: 1.0.0-rc.9
  › @tauri-apps/api [NPM]: 1.0.0-rc.4
  › tauri [RUST]: 1.0.0-rc.8,
  › tauri-build [RUST]: 1.0.0-rc.7,
  › tao [RUST]: 0.8.2,
  › wry [RUST]: 0.15.0,

App
  › build-type: bundle
  › CSP: default-src 'self' customprotocol: asset:; font-src https://fonts.gstatic.com; img-src 'self' asset: https://asset.localhost blob: data:; style-src 'unsafe-inline' 'self' https://fonts.googleapis.com
  › distDir: ../dist
  › devPath: http://localhost:5000/
  › framework: Svelte

App directory structure
  ├─ isolation-dist
  ├─ dist
  ├─ node_modules
  ├─ public
  ├─ src-tauri
  └─ src


### Stack trace

_No response_

### Additional context

_No response_
@keiya01
Copy link
Member Author

keiya01 commented May 1, 2022

https://github.com/tauri-apps/wry/blob/fd1dcc3cc5a290bfe4ae8de04064074109902432/src/webview/wkwebview/mod.rs#L498-L500

I understand that this issue will be fixed when forMainFrameOnly is changed to true.

@keiya01
Copy link
Member Author

keiya01 commented May 1, 2022

I find the same issue in windows.
Screen Shot 2022-05-02 at 1 39 59

But linux seems to be working.
Screen Shot 2022-05-02 at 1 44 26

@lucasfernog
Copy link
Member

I'm fixing it. Thanks for the report!

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