fastn-stack / fastn

🚧 (Alpha stage software) fastn - better way to build websites 🚧
https://fastn.com
GNU Affero General Public License v3.0
463 stars 36 forks source link

correctly render `srcdoc` attribute for `ftd.iframe` #1924

Closed siddhantk232 closed 2 weeks ago

siddhantk232 commented 2 weeks ago

Providing a caption (srcdoc) to ftd.iframe renders a src attribute. This is fixed in this PR.

The expected output html for the following ftd code:

-- ftd.iframe

<h1>hello world</h1>

should be:

<iframe srcdoc="<h1>hello world</h1>" />

but it is (notice the attribute is src):

<iframe src="<h1>hello world</h1>" />

The will result in an invalid url error in browsers.

siddhantk232 commented 2 weeks ago

seems like the only test failed is 'tests::fbt' panicked at fastn-core/src/lib.rs:207:13