react-email 5.2.4 → 5.2.5

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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # react-email
2
2
 
3
+ ## 5.2.5
4
+
5
+ ### Patch Changes
6
+
7
+ - 81aea00: revert changes to fix compatibility with alpine
8
+
3
9
  ## 5.2.4
4
10
 
5
11
  ### Patch Changes
package/dev/index.js CHANGED
@@ -13,6 +13,10 @@ const tsx = child_process.spawn(
13
13
  {
14
14
  cwd: process.cwd(),
15
15
  shell: true,
16
+ env: {
17
+ ...process.env,
18
+ NODE_OPTIONS: `${process.env.NODE_OPTIONS ?? ''} --experimental-vm-modules --disable-warning=ExperimentalWarning`,
19
+ },
16
20
  stdio: 'inherit',
17
21
  },
18
22
  );
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- #!/usr/bin/env node
1
+ #!/usr/bin/env -S node --experimental-vm-modules --disable-warning=ExperimentalWarning
2
2
  import { createRequire } from "node:module";
3
3
  import { program } from "commander";
4
4
  import fs, { existsSync, promises, statSync, unlinkSync, writeFileSync } from "node:fs";
@@ -87,7 +87,7 @@ const getEmailsDirectoryMetadata = async (absolutePathToEmailsDirectory, keepFil
87
87
  //#region package.json
88
88
  var package_default = {
89
89
  name: "react-email",
90
- version: "5.2.4",
90
+ version: "5.2.5",
91
91
  description: "A live preview of your emails right in your browser.",
92
92
  bin: { "email": "./dist/index.js" },
93
93
  type: "module",
@@ -238,8 +238,8 @@ export function generateStaticParams() {
238
238
  const updatePackageJson = async (builtPreviewAppPath) => {
239
239
  const packageJsonPath = path.resolve(builtPreviewAppPath, "./package.json");
240
240
  const packageJson = JSON.parse(await fs.promises.readFile(packageJsonPath, "utf8"));
241
- packageJson.scripts.build = "next build";
242
- packageJson.scripts.start = "next start";
241
+ packageJson.scripts.build = "cross-env NODE_OPTIONS=\"--experimental-vm-modules --disable-warning=ExperimentalWarning\" next build";
242
+ packageJson.scripts.start = "cross-env NODE_OPTIONS=\"--experimental-vm-modules --disable-warning=ExperimentalWarning\" next start";
243
243
  delete packageJson.scripts.postbuild;
244
244
  packageJson.name = "preview-server";
245
245
  for (const [dependency, version$1] of Object.entries(packageJson.devDependencies)) packageJson.devDependencies[dependency] = version$1.replace("workspace:", "");
@@ -294,7 +294,6 @@ const build$1 = async ({ dir: emailsDirRelativePath, packageManager }) => {
294
294
  });
295
295
  await runScript("build", {
296
296
  packageManager,
297
- env: { NODE_OPTIONS: "--experimental-vm-modules --disable-warning=ExperimentalWarning" },
298
297
  cwd: builtPreviewAppPath
299
298
  });
300
299
  } catch (error) {
@@ -582,7 +581,6 @@ const styleText = nodeUtil.styleText ? nodeUtil.styleText : (_, text) => text;
582
581
  //#region src/utils/preview/get-env-variables-for-preview-app.ts
583
582
  const getEnvVariablesForPreviewApp = (relativePathToEmailsDirectory, previewServerLocation, cwd, resendApiKey) => {
584
583
  return {
585
- NODE_OPTIONS: "--experimental-vm-modules --disable-warning=ExperimentalWarning",
586
584
  EMAILS_DIR_RELATIVE_PATH: relativePathToEmailsDirectory,
587
585
  EMAILS_DIR_ABSOLUTE_PATH: path.resolve(cwd, relativePathToEmailsDirectory),
588
586
  PREVIEW_SERVER_LOCATION: previewServerLocation,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-email",
3
- "version": "5.2.4",
3
+ "version": "5.2.5",
4
4
  "description": "A live preview of your emails right in your browser.",
5
5
  "bin": {
6
6
  "email": "./dist/index.js"
@@ -135,8 +135,10 @@ const updatePackageJson = async (builtPreviewAppPath: string) => {
135
135
  devDependencies: Record<string, string>;
136
136
  };
137
137
  // Turbopack has some errors with the imports in @react-email/tailwind
138
- packageJson.scripts.build = 'next build';
139
- packageJson.scripts.start = 'next start';
138
+ packageJson.scripts.build =
139
+ 'cross-env NODE_OPTIONS="--experimental-vm-modules --disable-warning=ExperimentalWarning" next build';
140
+ packageJson.scripts.start =
141
+ 'cross-env NODE_OPTIONS="--experimental-vm-modules --disable-warning=ExperimentalWarning" next start';
140
142
  delete packageJson.scripts.postbuild;
141
143
 
142
144
  packageJson.name = 'preview-server';
@@ -238,10 +240,6 @@ export const build = async ({
238
240
 
239
241
  await runScript('build', {
240
242
  packageManager,
241
- env: {
242
- NODE_OPTIONS:
243
- '--experimental-vm-modules --disable-warning=ExperimentalWarning',
244
- },
245
243
  cwd: builtPreviewAppPath,
246
244
  });
247
245
  } catch (error) {
package/src/index.ts CHANGED
@@ -1,4 +1,4 @@
1
- #!/usr/bin/env node
1
+ #!/usr/bin/env -S node --experimental-vm-modules --disable-warning=ExperimentalWarning
2
2
  import { program } from 'commander';
3
3
  import { build } from './commands/build.js';
4
4
  import { dev } from './commands/dev.js';
@@ -7,8 +7,6 @@ export const getEnvVariablesForPreviewApp = (
7
7
  resendApiKey?: string,
8
8
  ) => {
9
9
  return {
10
- NODE_OPTIONS:
11
- '--experimental-vm-modules --disable-warning=ExperimentalWarning',
12
10
  EMAILS_DIR_RELATIVE_PATH: relativePathToEmailsDirectory,
13
11
  EMAILS_DIR_ABSOLUTE_PATH: path.resolve(cwd, relativePathToEmailsDirectory),
14
12
  PREVIEW_SERVER_LOCATION: previewServerLocation,