Skip to content

Commit

Permalink
Add allowed iframes to fancy chat (#917)
Browse files Browse the repository at this point in the history
  • Loading branch information
richard-to committed Sep 1, 2024
1 parent ae488cd commit eb2e9fa
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion demo/fancy_chat.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,14 @@ def on_load(e: me.LoadEvent):
me.set_theme_mode("system")


@me.page(path="/fancy_chat", on_load=on_load)
@me.page(
security_policy=me.SecurityPolicy(
allowed_iframe_parents=["https://google.github.io"]
),
title="Fancy Mesop Demo Chat",
path="/fancy_chat",
on_load=on_load,
)
def page():
state = me.state(State)

Expand Down

0 comments on commit eb2e9fa

Please sign in to comment.