Skip to content

Commit

Permalink
Update ARCitect-Swate communication to prepare for future features.
Browse files Browse the repository at this point in the history
  • Loading branch information
Freymaurer committed Oct 16, 2024
1 parent b7da9fd commit c5c740e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Client/ARCitect/Interop.fs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module ARCitect.Interop
module ARCitect.Interop

open Fable.Core.JsInterop
open Model.ARCitect
Expand Down Expand Up @@ -33,7 +33,7 @@ let inline runApiFromName (apiHandler: 'E) (apiName: string) (data: 'A) =
let inline postMessageToARCitect (msg: 'A, data) =
let methodName = getUnionCaseName msg
let createContent (data) = {|swate = true; api = methodName; data = data|}
Browser.Dom.window.top.postMessage(createContent data, "*")
Browser.Dom.window.parent.postMessage(createContent data, "*")

/// <summary>
/// Returns a function to remove the event listener
Expand Down
1 change: 1 addition & 0 deletions src/Client/Client.fs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ open Messages
open Model
open Update
open Fable.Core.JsInterop

importSideEffects "./style.scss"
importSideEffects "./tailwindstyle.scss"

Expand Down

0 comments on commit c5c740e

Please sign in to comment.