Skip to content

Commit

Permalink
fix: twitter (support both x.com and twitter.com) urls
Browse files Browse the repository at this point in the history
  • Loading branch information
hortopan authored May 17, 2024
1 parent dfdbf24 commit 4d5ea53
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/services.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ export default {
width: 400,
},
twitter: {
regex: /^https?:\/\/(www\.)?twitter\.com\/.+\/status\/(\d+)/,
regex: /^https?:\/\/(www\.)?(twitter|x)\.com\/.+\/status\/(\d+)/,
embedUrl: 'https://platform.twitter.com/embed/Tweet.html?id=<%= remote_id %>',
html: '<iframe width="600" height="600" style="margin: 0 auto;" frameborder="0" scrolling="no" allowtransparency="true"></iframe>',
height: 300,
Expand Down

0 comments on commit 4d5ea53

Please sign in to comment.