feat: embed youtube videos #13
No reviewers
Labels
No Label
1000k
100k
10k
200k
20k
500k
50k
5k
75k
backend
blocked:design
bug
dependencies
documentation
duplicate
enhancement
good first issue
help wanted
invalid
P1
P2
P3
question
scope:intl
scope:nip
scope:query_tracing
scope:ux
wontfix
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Kieran/snort#13
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "youtube"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Deploying with Cloudflare Pages
11c5dc0
View logs
@ -6,1 +6,4 @@
function transformHttpLink(a) {
try {
const url = new URL(a);
I would make this a separate function to iterate over fragments and have another Regex to parse the youtube links, can see this being the case for other sources in the future too
We could also add some breaks around this: https://ab0a921a.snort-social.pages.dev/e/note1mju85jc587326vqgjkkn9f4sy5c4a578azayzhy4q0f54m4qslusfehluj
Also styling should be extended for youtube iframes
7831bdbcc2/src/element/Note.css (L25-L28)
@v0l addressed your comments, I think is best to transform HTTP links in one pass, added a better regex for extracting youtube vid ids.