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

fix: getPayload generate import map only in Next.js #9371

Merged
merged 3 commits into from
Dec 4, 2024

Conversation

r1tsuu
Copy link
Member

@r1tsuu r1tsuu commented Nov 20, 2024

After the change with removing getPayloadHMR, we do generate import map even outside of Next.js, which leads to errors when using in a project without it:
image

@r1tsuu r1tsuu requested a review from denolfe as a code owner November 20, 2024 10:29
@r1tsuu r1tsuu force-pushed the fix/get-payload-without-next-js branch from 03cffa2 to 925cb03 Compare November 20, 2024 12:57
@fofoy
Copy link
Contributor

fofoy commented Nov 27, 2024

Hey @r1tsuu, thanks again for this PR, is there anything blocking this PR being merged ?

I also noticed and reported on Discord that when we load Payload outside of Next.js, the email configuration is trying to load, generating errors related to Nodemailer like so, I guess it's not exactly normal when we just want to use the Local API, what do you think ?

image

@r1tsuu
Copy link
Member Author

r1tsuu commented Nov 27, 2024

Hey @r1tsuu, thanks again for this PR, is there anything blocking this PR being merged ?

I also noticed and reported on Discord that when we load Payload outside of Next.js, the email configuration is trying to load, generating errors related to Nodemailer like so, I guess it's not exactly normal when we just want to use the Local API, what do you think ?

image

I don't think, but need some eyes on it. Do you have this specific error that PR fixes?

@fofoy
Copy link
Contributor

fofoy commented Nov 27, 2024

That's another one I'm getting on either 3.0.2-canary.03cffa2 or 3.2.0 but since that was kind of related if thought I'd mention it there. I can open another issue if you prefer !

@r1tsuu
Copy link
Member Author

r1tsuu commented Nov 27, 2024

That would be nice!

@r1tsuu r1tsuu force-pushed the fix/get-payload-without-next-js branch from 925cb03 to e39235f Compare December 4, 2024 19:03
@r1tsuu r1tsuu changed the title fix: getPayload generate import map only in Next.js, move ws dependency to @payloadcms/next fix: getPayload generate import map only in Next.js Dec 4, 2024
@AlessioGr AlessioGr enabled auto-merge (squash) December 4, 2024 19:24
@AlessioGr AlessioGr merged commit d8f7034 into main Dec 4, 2024
53 checks passed
@AlessioGr AlessioGr deleted the fix/get-payload-without-next-js branch December 4, 2024 19:46
Copy link
Contributor

github-actions bot commented Dec 6, 2024

🚀 This is included in version v3.5.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants