gkucmierz / social-links

Validate & sanitize social links
https://npmjs.com/package/social-links
MIT License
28 stars 14 forks source link

Issue with new youtube handles #37

Closed segli closed 1 year ago

segli commented 1 year ago

New Youtube handles are not supported. E.g. https://youtube.com/@icfchurch.zurich. I wanted to add a new match to the YT profile, but it looks like multiple patterns of the same type (e.g. desktop) are not supported.

./lib/profiles/youtube.js


    {
        match: '(https?://)?(www.)?youtube.com/@({PROFILE_ID})/?', group: 3, type: types_1.TYPE_DESKTOP,
        pattern: 'https://youtube.com/@{PROFILE_ID}'
    },
`

Any ideas how this could easily be implemented? Thanks a lot!
gkucmierz commented 1 year ago

What is not working on your side?

Which version do you use?

It is working for me on v1.10.0 https://github.com/gkucmierz/social-links/blob/789ca30f1bd57a70aa5a3621d46763d266859330/src/profiles/youtube.ts#L7-L10

Screenshot 2022-12-02 at 03 08 07
segli commented 1 year ago

Thanks and sorry! I haven't updated to the latest version... :-) It's working!