You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please add a reproduction in order for us to be able to investigate.
Depending on the quality of reproduction steps, this issue may be closed if no reproduction is provided.
Why was this issue marked with the invalid-reproduction label?
To be able to investigate, we need access to a reproduction to identify what triggered the issue. We prefer a link to a public GitHub repository created with create-payload-app@latest -t blank or a forked/branched version of this repository with tests added (more info in the reproduction-guide).
To make sure the issue is resolved as quickly as possible, please make sure that the reproduction is as minimal as possible. This means that you should remove unnecessary code, files, and dependencies that do not contribute to the issue. Ensure your reproduction does not depend on secrets, 3rd party registries, private dependencies, or any other data that cannot be made public. Avoid a reproduction including a whole monorepo (unless relevant to the issue). The easier it is to reproduce the issue, the quicker we can help.
Please test your reproduction against the latest version of Payload to make sure your issue has not already been fixed.
I added a link, why was it still marked?
Ensure the link is pointing to a codebase that is accessible (e.g. not a private repository). "example.com", "n/a", "will add later", etc. are not acceptable links -- we need to see a public codebase. See the above section for accepted links.
Are you able to provide a reproduction for us please? We have quite a few test suites using live preview so it is working in most setups still
I've also noticed in your package list that translations are "@payloadcms/translations": "^3.58.0", you should pin the version here to ensure it doesn't ever deviate from the rest of the packages
Hi @paulpopus, i have created an example for you. It is an Angular app that goes to a static route in the CMS in CmsService. You will need to adapt this yourself.
I can also reproduce this issue with the latest Payload versions. The PostMessage event with type payload-document-event is not sent to the page in the iframe anymore.
The part that you were missing is telling the admin panel that your frontend is ready to receive the messages by adding this after the subscribe
// add ready importimport{ready}from"@payloadcms/live-preview";// in onNgInitready({serverURL: environment.twoMhCms});
Also when fetching data since we utilise draft data for live preview so your data fetching should instead be with draft=true in the case of live preview being enabled.
Some extra tips for setting this up in a performant way, I'm not sure about Angular equivalents but in Nextjs we have draftMode() as an API that allows us to toggle drafts dynamically without breaking our static site and you may need to do something similar - we have this behind authentication as well just to be clear so only admins can actually enter this draft mode.
Then based on that cookie, header or param however you wish to do it, you would enable drafts in your data fetching. Our website template, uses this pattern.
To further help you with data fetching you can also try using the API SDK if it makes some APIs easier.
Activity
github-actions commentedon Oct 2, 2025
Please add a reproduction in order for us to be able to investigate.
Depending on the quality of reproduction steps, this issue may be closed if no reproduction is provided.
Why was this issue marked with the
invalid-reproductionlabel?To be able to investigate, we need access to a reproduction to identify what triggered the issue. We prefer a link to a public GitHub repository created with
create-payload-app@latest -t blankor a forked/branched version of this repository with tests added (more info in the reproduction-guide).To make sure the issue is resolved as quickly as possible, please make sure that the reproduction is as minimal as possible. This means that you should remove unnecessary code, files, and dependencies that do not contribute to the issue. Ensure your reproduction does not depend on secrets, 3rd party registries, private dependencies, or any other data that cannot be made public. Avoid a reproduction including a whole monorepo (unless relevant to the issue). The easier it is to reproduce the issue, the quicker we can help.
Please test your reproduction against the latest version of Payload to make sure your issue has not already been fixed.
I added a link, why was it still marked?
Ensure the link is pointing to a codebase that is accessible (e.g. not a private repository). "example.com", "n/a", "will add later", etc. are not acceptable links -- we need to see a public codebase. See the above section for accepted links.
Useful Resources
orhancelik1 commentedon Oct 7, 2025
I have the same issue. It is working in 3.54.0 but not working in 3.58.0
orhancelik1 commentedon Oct 30, 2025
I fixed it with updating all packages same version including "@payloadcms/live-preview-react"
philippkdhl commentedon Oct 31, 2025
Unfortunately not in my case.
I think the bug comes with this PR: #13631
philippkdhl commentedon Oct 31, 2025
this is not working since 3.58.0 or 3.57.0
paulpopus commentedon Oct 31, 2025
Are you able to provide a reproduction for us please? We have quite a few test suites using live preview so it is working in most setups still
I've also noticed in your package list that translations are
"@payloadcms/translations": "^3.58.0", you should pin the version here to ensure it doesn't ever deviate from the rest of the packagesphilippkdhl commentedon Oct 31, 2025
What exactly do you need from me? Should I provide a sample project with the CMS and an Angular app?
philippkdhl commentedon Nov 3, 2025
@paulpopus Should I provide a sample project with the CMS and an Angular app?
paulpopus commentedon Nov 3, 2025
@philippkdhl yes please, just a minimum reproduction needed that we can run to see what the issue might be
philippkdhl commentedon Nov 3, 2025
cms.zip
Hi @paulpopus, i have created an example for you. It is an Angular app that goes to a static route in the CMS in CmsService. You will need to adapt this yourself.
paulpopus commentedon Nov 3, 2025
@philippkdhl Could you put this up on a public github repo please? For security we can't really open random zips from the internet
philippkdhl commentedon Nov 3, 2025
Hi @paulpopus --> https://github.com/philippkdhl/payload-angular-example
can you access ?
paulpopus commentedon Nov 3, 2025
Yes I can, thank you @philippkdhl
jhb-dev commentedon Nov 13, 2025
I can also reproduce this issue with the latest Payload versions. The PostMessage event with type
payload-document-eventis not sent to the page in the iframe anymore.paulpopus commentedon Nov 18, 2025
Hey everyone, so I pulled down the repo and live preview works as expected for me following the docs here https://payloadcms.com/docs/live-preview/client#building-your-own-hook
The part that you were missing is telling the admin panel that your frontend is ready to receive the messages by adding this after the subscribe
Also when fetching data since we utilise draft data for live preview so your data fetching should instead be with
draft=truein the case of live preview being enabled.Some extra tips for setting this up in a performant way, I'm not sure about Angular equivalents but in Nextjs we have
draftMode()as an API that allows us to toggle drafts dynamically without breaking our static site and you may need to do something similar - we have this behind authentication as well just to be clear so only admins can actually enter this draft mode.Then based on that cookie, header or param however you wish to do it, you would enable drafts in your data fetching. Our website template, uses this pattern.
To further help you with data fetching you can also try using the API SDK if it makes some APIs easier.
philippkdhl commentedon Nov 19, 2025
Perfect! Thank you for this hint :)
It works now!
github-actions commentedon Nov 27, 2025
This issue has been automatically locked.
Please open a new issue if this issue persists with any additional detail.