Skip to content

Trunk 0.21.6 causes CORS related issues when used with tauri, which causes CSS attributes not being applied #941

@hrzlgnm

Description

@hrzlgnm

What I could observe so far:

After updating trunk to 0.21.6, all styles used in were somehow not applied. I can observe the following errors in developer tools, when enabled in debug mode:

Refused to load http://localhost:1420/styles-8594f9560b2c9a3f.css because it does not appear in the style-src directive of the Content Security Policy.

Steps to reproduce:

cargo install --locked trunk@0.21.6 --no-default-features --features=rustls
cargo install --locked tauri-cli
cargo install create-tauri-app --locked
cargo create-tauri-app
cargo create-tauri-app -m cargo -t leptos -y my-app
cd my-app
cargo --locked  tauri dev

Expect something similar to the following screenshot to be shown:

Image

Actual result:

Image

The issue is reproducible on linux and on windows.

In the meantime I went back to 0.21.5 which works fine, and doesn't cause those issues.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions