farm-fe / farm

Extremely fast Vite-compatible web build tool written in Rust
https://farmfe.org
MIT License
4.82k stars 158 forks source link

[Bug Report]: script data-farm-entry-script="true" is added to HTML breaking CSP #1710

Closed ddorstijn closed 3 days ago

ddorstijn commented 1 month ago

Steps to reproduce

Create a default farm project. Build the project. The HTML suddenly has multiple script tags with data-farm-entry-script="true".

Reproduce link

No response

What is actually happening?

Some scripts get generated and I can't seem to disable it in any way. I built a web extension and cannot have any inline javascript. I can't use Farm at the moment because these scripts get added to the html

System Info

System:
    OS: Windows 11 10.0.22631
    CPU: (6) x64 AMD Ryzen 5 4500U with Radeon Graphics
    Memory: 4.94 GB / 15.37 GB
  Binaries:
    Node: 22.5.1 - ~\scoop\apps\nodejs\current\node.EXE
    Yarn: 1.22.22 - ~\scoop\apps\yarn\current\bin\yarn.CMD
    npm: 10.8.2 - ~\scoop\apps\nodejs\current\npm.CMD
    pnpm: 9.6.0 - ~\scoop\shims\pnpm.EXE
  Browsers:
    Edge: Chromium (127.0.2651.74)
    Internet Explorer: 11.0.22621.3527
  npmPackages:
    @farmfe/core: ^1.3.0 => 1.3.12
wre232114 commented 1 month ago

We'll support removing the tags next patch