Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Embed doesn't recognise Instagram reels #92

Open
Eliam93 opened this issue May 25, 2022 · 3 comments
Open

Embed doesn't recognise Instagram reels #92

Eliam93 opened this issue May 25, 2022 · 3 comments
Labels
good first issue Good for newcomers

Comments

@Eliam93
Copy link

Eliam93 commented May 25, 2022

Hi,
I'm trying to embed a reel URL, but it doesn't work as for Ig posts. There is any chance to embed that? Thanks

@kentarohorie
Copy link
Contributor

It seems that embedding not work when URL has query parameter.

https://www.instagram.com/p/CfQzzGNphD8/?utm_source=ig_web_copy_link -> not work
https://www.instagram.com/p/CfQzzGNphD8/ -> work

@kentarohorie
Copy link
Contributor

I made a mistake. My problem not relate with this issue.

@Swanand01
Copy link

instagramPost: {
    regex: /https?:\/\/www\.instagram\.com\/p\/([^\/\?\&]+)\/?([\s\S]*)\/?/,
    embedUrl: "https://www.instagram.com/p/<%= remote_id %>/embed",
    html: '<iframe width="400" height="505" style="margin: 0 auto;" frameborder="0" scrolling="no" allowtransparency="true"></iframe>',
    height: 505,
    width: 400,
    id: (groups) => {
        return groups[0];
    }
}
instagramReel: {
    regex: /https?:\/\/www\.instagram\.com\/reel\/([^\/\?\&]+)\/?([\s\S]*)\/?/,
    embedUrl: "https://www.instagram.com/reel/<%= remote_id %>/embed",
    html: '<iframe width="400" height="600" style="margin: 0 auto;" frameborder="0" scrolling="no" allowtransparency="true"></iframe>',
    height: 600,
    width: 400,
    id: (groups) => {
        return groups[0];
    }
}

These two configs worked for me. You'll have to add these to the config object when you instantiate the EditorJS object.

@neSpecc neSpecc added the good first issue Good for newcomers label Aug 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants