'youtube'/'vimeo' are detected by core's DOM scanning too (§2.1) —
cheap, dependency-free URL parsing, not the provider's SDK. Rendering
any non-'html5' provider is a plugin's job (§4-video), via
ctx.ui.registerVideoProvider() or 'custom''s own render.
id is optional on the youtube/vimeo variant so dynamic-mode hosts can
write video: { provider: 'youtube' } and let id be filled in from
src (scan.ts's resolveDynamicVideoItems) — same reasoning as
video: true above, just with the provider spelled out explicitly. A
rendered item with no id (src wasn't a recognized URL either) shows a
placeholder instead of a broken embed — see youtube.ts/vimeo.ts.
'youtube'/'vimeo'are detected by core's DOM scanning too (§2.1) — cheap, dependency-free URL parsing, not the provider's SDK. Rendering any non-'html5'provider is a plugin's job (§4-video), viactx.ui.registerVideoProvider()or'custom''s ownrender.idis optional on the youtube/vimeo variant so dynamic-mode hosts can writevideo: { provider: 'youtube' }and letidbe filled in fromsrc(scan.ts'sresolveDynamicVideoItems) — same reasoning asvideo: trueabove, just with the provider spelled out explicitly. A rendered item with noid(src wasn't a recognized URL either) shows a placeholder instead of a broken embed — seeyoutube.ts/vimeo.ts.