Skip to content

fix(react-email): Dependents of dependents of email templates not causing hot reloads #2083

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

Conversation

gabrielmfern
Copy link
Collaborator

@gabrielmfern gabrielmfern commented Apr 14, 2025

Meant for #2078.

The main problem was that the component was being treated as an email template on the hot reloading code which is then fixed with

if (
containsEmailTemplate(slugForChangedEmail, emailsDirectoryMetadata)
) {
continue;
}

Alongside a unit test to ensure this function works as intended. This PR also ends up fixing the error in #1872 (comment)

@gabrielmfern gabrielmfern added the Package: react-email This is the CLI we generally use as just `email` on the temrinal. label Apr 14, 2025
@gabrielmfern gabrielmfern self-assigned this Apr 14, 2025
Copy link

changeset-bot bot commented Apr 14, 2025

🦋 Changeset detected

Latest commit: 6685b5b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
react-email Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Apr 14, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-email ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 14, 2025 7:38pm
react-email-demo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 14, 2025 7:38pm

@gabrielmfern gabrielmfern merged commit a587e17 into canary Apr 14, 2025
10 checks passed
@gabrielmfern gabrielmfern deleted the feature/eng-4073-fix-dependents-of-dependents-of-email-templates-not branch April 14, 2025 19:41
bukinoshita pushed a commit that referenced this pull request Apr 19, 2025
gabrielmfern added a commit that referenced this pull request Apr 23, 2025
gabrielmfern added a commit that referenced this pull request Apr 23, 2025
gabrielmfern added a commit that referenced this pull request Apr 23, 2025
gabrielmfern added a commit that referenced this pull request Apr 24, 2025
gabrielmfern added a commit that referenced this pull request Apr 24, 2025
gabrielmfern added a commit that referenced this pull request Apr 24, 2025
gabrielmfern added a commit that referenced this pull request Apr 25, 2025
gabrielmfern added a commit that referenced this pull request May 1, 2025
gabrielmfern added a commit that referenced this pull request May 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: react-email This is the CLI we generally use as just `email` on the temrinal.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant