react-email 4.2.10 → 4.2.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-email",
3
- "version": "4.2.10",
3
+ "version": "4.2.12",
4
4
  "description": "A live preview of your emails right in your browser.",
5
5
  "bin": {
6
6
  "email": "./dist/index.js"
@@ -45,13 +45,12 @@
45
45
  "next": "^15.3.2",
46
46
  "react": "19.0.0",
47
47
  "react-dom": "19.0.0",
48
- "tsup": "8.4.0",
49
48
  "typescript": "5.8.3",
50
- "@react-email/components": "0.5.3"
49
+ "@react-email/components": "0.5.5"
51
50
  },
52
51
  "scripts": {
53
- "build": "tsup-node",
54
- "build:watch": "tsup-node --watch src",
52
+ "build": "tsdown",
53
+ "build:watch": "tsdown --watch src",
55
54
  "clean": "rm -rf dist",
56
55
  "test": "vitest run",
57
56
  "test:watch": "vitest"
package/readme.md CHANGED
@@ -4,11 +4,10 @@
4
4
  <div align="center">The next generation of writing emails.<br />High-quality, unstyled components for creating emails.</div>
5
5
  <br />
6
6
  <div align="center">
7
- <a href="https://react.email">Website</a>
7
+ <a href="https://react.email">Website</a>
8
8
  <span> · </span>
9
- <a href="https://github.com/resend/react-email">GitHub</a>
10
- <span> · </span>
11
- <a href="https://react.email/discord">Discord</a>
9
+ <a href="https://github.com/resend/react-email">GitHub</a>
10
+
12
11
  </div>
13
12
 
14
13
  ## Getting started
@@ -78,14 +78,14 @@ const setNextEnvironmentVariablesForBuild = async (
78
78
  const nextConfigContents = `
79
79
  const path = require('path');
80
80
  const emailsDirRelativePath = path.normalize('${emailsDirRelativePath}');
81
- const userProjectLocation = '${process.cwd()}';
81
+ const userProjectLocation = '${process.cwd().replace(/\\/g, '/')}';
82
82
  /** @type {import('next').NextConfig} */
83
83
  module.exports = {
84
84
  env: {
85
85
  NEXT_PUBLIC_IS_BUILDING: 'true',
86
86
  EMAILS_DIR_RELATIVE_PATH: emailsDirRelativePath,
87
87
  EMAILS_DIR_ABSOLUTE_PATH: path.resolve(userProjectLocation, emailsDirRelativePath),
88
- PREVIEW_SERVER_LOCATION: '${builtPreviewAppPath}',
88
+ PREVIEW_SERVER_LOCATION: '${builtPreviewAppPath.replace(/\\/g, '/')}',
89
89
  USER_PROJECT_LOCATION: userProjectLocation
90
90
  },
91
91
  // this is needed so that the code for building emails works properly
@@ -154,9 +154,9 @@ const forceSSGForEmailPreviews = async (
154
154
  emailsDirPath: string,
155
155
  builtPreviewAppPath: string,
156
156
  ) => {
157
- const emailDirectoryMetadata =
158
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
159
- (await getEmailsDirectoryMetadata(emailsDirPath))!;
157
+ const emailDirectoryMetadata = (await getEmailsDirectoryMetadata(
158
+ emailsDirPath,
159
+ ))!;
160
160
 
161
161
  const parameters = getEmailSlugsFromEmailDirectory(
162
162
  emailDirectoryMetadata,
@@ -1,4 +1,3 @@
1
- /* eslint-disable @typescript-eslint/no-non-null-assertion */
2
1
  import fs from 'node:fs';
3
2
  import path from 'node:path';
4
3
 
@@ -1,5 +1,4 @@
1
1
  import { existsSync, promises as fs } from 'node:fs';
2
- /* eslint-disable @typescript-eslint/no-non-null-assertion */
3
2
  import type http from 'node:http';
4
3
  import path from 'node:path';
5
4
  import type url from 'node:url';
@@ -83,8 +83,6 @@ export const startDevServer = async (
83
83
  const { portAlreadyInUse } = await safeAsyncServerListen(devServer, port);
84
84
 
85
85
  if (!portAlreadyInUse) {
86
- // this errors when linting but doesn't on the editor so ignore the warning on this
87
- /* eslint-disable-next-line @typescript-eslint/no-unsafe-member-access */
88
86
  console.log(
89
87
  styleText('greenBright', ` React Email ${packageJson.version}`),
90
88
  );
@@ -0,0 +1,8 @@
1
+ import { defineConfig } from 'tsdown';
2
+
3
+ export default defineConfig({
4
+ dts: false,
5
+ entry: ['./src/index.ts'],
6
+ format: ['esm'],
7
+ outDir: 'dist',
8
+ });