Skip to content

"useLocalHTML" ?? #125

Answered by LonelyCpp
pairohit305 asked this question in Q&A
Mar 31, 2021 · 1 comments · 2 replies
Discussion options

You must be logged in to vote

There are two ways to render the youtube player in the webview.

  1. generate HTML based on the props and give it to webview as raw HTML string (code)

    • advantages: no need to load an extra webpage.
    • disadvantages: page will not have a domain name leading to some videos being "unavailable"
  2. host the HTML on a remote source (github pages by default) and pass information with query parameters (code)

    • advantages: has a trusted domain name, which prevents all "unavailable" errors.
    • disadvantages: extra 3kb page load, github source could be unavailable (unlikely)

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@pairohit305
Comment options

@LonelyCpp
Comment options

Answer selected by pairohit305
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants