flutter_html icon indicating copy to clipboard operation
flutter_html copied to clipboard

fix: enable JavaScript in iframe

Open DocMarty84 opened this issue 1 year ago • 0 comments

When an iframe contains the sandbox attribute, its value must be exactly allow-scripts in order to enable JavaScript. However, in many cases the attribute has more than one value. Here is an example:^1

sandbox="allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox"

We make the condition more flexible by using contains.

Fixes https://github.com/DocMarty84/miniflutt/issues/30

DocMarty84 avatar May 12 '24 21:05 DocMarty84