Skip to content

Commit

Permalink
Adds ready for rendering function in the emulator.
Browse files Browse the repository at this point in the history
It does nothing in the emulator.
  • Loading branch information
sergey-borovkov committed Sep 11, 2024
1 parent 2a9fe64 commit 46ae998
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/commands/edge_app/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ fn format_js(data: MockData, secrets: &[(String, Value)]) -> String {
settings.sort_by_key(|a| a.0.clone());

format!(
"var screenly = {{\n{metadata},\n{settings},\n{cors_proxy}\n}};",
"var screenly = {{\n{metadata},\n{settings},\n{cors_proxy},\n signalReadyForRendering: function() {{}}\n}};",
metadata = format_section("metadata", &hashmap_from_metadata(&data.metadata)),
settings = format_section("settings", &settings),
cors_proxy = " cors_proxy_url: \"http://127.0.0.1:8080\""
Expand Down Expand Up @@ -395,7 +395,8 @@ settings:
"override_timezone": "",
"tag_manager_id": ""
},
cors_proxy_url: "http://127.0.0.1:8080"
cors_proxy_url: "http://127.0.0.1:8080",
signalReadyForRendering: function() {}
};"#;
assert_eq!(content, expected_content);
}
Expand Down

0 comments on commit 46ae998

Please sign in to comment.