react-email 1.9.5 → 1.10.0
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/.eslintrc.js +5 -2
- package/dist/package.json +10 -13
- package/dist/source/commands/dev.d.ts +1 -0
- package/dist/source/commands/dev.d.ts.map +1 -0
- package/dist/source/commands/dev.js +72 -20
- package/dist/source/commands/export.d.ts +2 -1
- package/dist/source/commands/export.d.ts.map +1 -0
- package/dist/source/commands/export.js +137 -57
- package/dist/source/commands/preview.d.ts +1 -0
- package/dist/source/commands/preview.d.ts.map +1 -0
- package/dist/source/commands/preview.js +98 -30
- package/dist/source/index.d.ts +1 -0
- package/dist/source/index.d.ts.map +1 -0
- package/dist/source/index.js +11 -7
- package/dist/source/utils/close-ora-on-sigint.d.ts +2 -1
- package/dist/source/utils/close-ora-on-sigint.d.ts.map +1 -0
- package/dist/source/utils/close-ora-on-sigint.js +1 -1
- package/dist/source/utils/constants.d.ts +1 -0
- package/dist/source/utils/constants.d.ts.map +1 -0
- package/dist/source/utils/constants.js +6 -6
- package/dist/source/utils/convert-to-absolute-path.d.ts +1 -0
- package/dist/source/utils/convert-to-absolute-path.d.ts.map +1 -0
- package/dist/source/utils/convert-to-absolute-path.js +4 -2
- package/dist/source/utils/download-client.d.ts +1 -0
- package/dist/source/utils/download-client.d.ts.map +1 -0
- package/dist/source/utils/download-client.js +63 -18
- package/dist/source/utils/generate-email-preview.d.ts +1 -0
- package/dist/source/utils/generate-email-preview.d.ts.map +1 -0
- package/dist/source/utils/generate-email-preview.js +122 -63
- package/dist/source/utils/index.d.ts +1 -0
- package/dist/source/utils/index.d.ts.map +1 -0
- package/dist/source/utils/install-dependencies.d.ts +2 -1
- package/dist/source/utils/install-dependencies.d.ts.map +1 -0
- package/dist/source/utils/install-dependencies.js +10 -10
- package/dist/source/utils/run-server.d.ts +4 -3
- package/dist/source/utils/run-server.d.ts.map +1 -0
- package/dist/source/utils/run-server.js +90 -37
- package/dist/source/utils/start-server-command.d.ts +1 -0
- package/dist/source/utils/start-server-command.d.ts.map +1 -0
- package/dist/source/utils/start-server-command.js +17 -17
- package/dist/source/utils/sync-package.d.ts +1 -0
- package/dist/source/utils/sync-package.d.ts.map +1 -0
- package/dist/source/utils/sync-package.js +69 -16
- package/dist/source/utils/tree.d.ts +2 -0
- package/dist/source/utils/tree.d.ts.map +1 -0
- package/dist/source/utils/tree.js +58 -0
- package/dist/source/utils/watcher.d.ts +3 -2
- package/dist/source/utils/watcher.d.ts.map +1 -0
- package/dist/source/utils/watcher.js +21 -27
- package/package.json +10 -13
- package/source/commands/dev.ts +2 -2
- package/source/commands/export.ts +48 -20
- package/source/commands/preview.ts +1 -1
- package/source/index.ts +2 -1
- package/source/utils/close-ora-on-sigint.ts +2 -2
- package/source/utils/constants.ts +1 -1
- package/source/utils/convert-to-absolute-path.ts +1 -1
- package/source/utils/download-client.ts +3 -3
- package/source/utils/generate-email-preview.ts +32 -36
- package/source/utils/install-dependencies.ts +3 -3
- package/source/utils/run-server.ts +9 -9
- package/source/utils/start-server-command.ts +2 -2
- package/source/utils/sync-package.ts +2 -2
- package/source/utils/tree.ts +10 -0
- package/source/utils/watcher.ts +14 -22
- package/tsconfig.export.json +31 -0
- package/tsconfig.json +8 -31
- package/.yarn/cache/@babel-code-frame-npm-7.18.6-25229a7e34-195e2be317.zip +0 -0
- package/.yarn/cache/@babel-helper-validator-identifier-npm-7.19.1-d84f19e1dc-0eca5e86a7.zip +0 -0
- package/.yarn/cache/@babel-highlight-npm-7.18.6-9d35ad2e27-92d8ee6154.zip +0 -0
- package/.yarn/cache/@commander-js-extra-typings-npm-9.4.1-b0399e3b65-d69cd1c2b5.zip +0 -0
- package/.yarn/cache/@cspotcode-source-map-support-npm-0.8.1-964f2de99d-5718f26708.zip +0 -0
- package/.yarn/cache/@esbuild-darwin-arm64-npm-0.16.4-96d7e8a733-8.zip +0 -0
- package/.yarn/cache/@isaacs-cliui-npm-8.0.2-f4364666d5-4a473b9b32.zip +0 -0
- package/.yarn/cache/@jridgewell-resolve-uri-npm-3.1.0-6ff2351e61-b5ceaaf9a1.zip +0 -0
- package/.yarn/cache/@jridgewell-sourcemap-codec-npm-1.4.14-f5f0630788-61100637b6.zip +0 -0
- package/.yarn/cache/@jridgewell-trace-mapping-npm-0.3.9-91625cd7fb-d89597752f.zip +0 -0
- package/.yarn/cache/@manypkg-find-root-npm-2.2.1-6ca5d93706-7f31120c3e.zip +0 -0
- package/.yarn/cache/@manypkg-tools-npm-1.1.0-1975c91c51-f0228435c0.zip +0 -0
- package/.yarn/cache/@nodelib-fs.scandir-npm-2.1.5-89c67370dd-a970d595bd.zip +0 -0
- package/.yarn/cache/@nodelib-fs.stat-npm-2.0.5-01f4dd3030-012480b5ca.zip +0 -0
- package/.yarn/cache/@nodelib-fs.walk-npm-1.2.8-b4a89da548-190c643f15.zip +0 -0
- package/.yarn/cache/@npmcli-fs-npm-3.1.0-0844a57978-a50a6818de.zip +0 -0
- package/.yarn/cache/@octokit-auth-token-npm-3.0.3-6fba099166-9b3f569cec.zip +0 -0
- package/.yarn/cache/@octokit-core-npm-4.2.0-0f3a7f3979-5ac56e7f14.zip +0 -0
- package/.yarn/cache/@octokit-endpoint-npm-7.0.5-82841b7e23-81c9e9eabf.zip +0 -0
- package/.yarn/cache/@octokit-graphql-npm-5.0.5-0534ea7757-eb2d1a6305.zip +0 -0
- package/.yarn/cache/@octokit-openapi-types-npm-16.0.0-2fe91e346e-844f30a545.zip +0 -0
- package/.yarn/cache/@octokit-plugin-paginate-rest-npm-6.0.0-ccfed9f0b1-4ad89568d8.zip +0 -0
- package/.yarn/cache/@octokit-plugin-request-log-npm-1.0.4-9ab5a2f888-2086db0005.zip +0 -0
- package/.yarn/cache/@octokit-plugin-rest-endpoint-methods-npm-7.0.1-6524223f9b-cdb8734ec9.zip +0 -0
- package/.yarn/cache/@octokit-request-error-npm-3.0.3-cbba4d6220-5db0b51473.zip +0 -0
- package/.yarn/cache/@octokit-request-npm-6.2.3-1b72fec7bb-fef4097be8.zip +0 -0
- package/.yarn/cache/@octokit-rest-npm-19.0.7-f05ed3b2ee-1f970c4de2.zip +0 -0
- package/.yarn/cache/@octokit-types-npm-9.0.0-3a83131100-5c7f5cca8f.zip +0 -0
- package/.yarn/cache/@pkgjs-parseargs-npm-0.11.0-cd2a3fe948-6ad6a00fc4.zip +0 -0
- package/.yarn/cache/@react-email-render-npm-0.0.6-aba674abb4-fe1f044305.zip +0 -0
- package/.yarn/cache/@selderee-plugin-htmlparser2-npm-0.10.0-da625619f9-37b5e059f0.zip +0 -0
- package/.yarn/cache/@tootallnate-once-npm-2.0.0-e36cf4f140-ad87447820.zip +0 -0
- package/.yarn/cache/@tsconfig-node10-npm-1.0.9-f2e2d20feb-a33ae4dc2a.zip +0 -0
- package/.yarn/cache/@tsconfig-node12-npm-1.0.11-9710d1c61b-5ce29a41b1.zip +0 -0
- package/.yarn/cache/@tsconfig-node14-npm-1.0.3-15321421d2-19275fe80c.zip +0 -0
- package/.yarn/cache/@tsconfig-node16-npm-1.0.3-6a4a30eda2-3a8b657dd0.zip +0 -0
- package/.yarn/cache/@types-fs-extra-npm-11.0.1-f11620397b-3e930346e5.zip +0 -0
- package/.yarn/cache/@types-glob-npm-7.2.0-772334bf9a-6ae717fedf.zip +0 -0
- package/.yarn/cache/@types-jsonfile-npm-6.1.1-62ad833c58-0f8fe0a922.zip +0 -0
- package/.yarn/cache/@types-minimatch-npm-5.1.2-aab9c394d3-0391a28286.zip +0 -0
- package/.yarn/cache/@types-node-npm-18.11.10-cca0d46cb2-0f60cb090b.zip +0 -0
- package/.yarn/cache/@types-node-npm-18.11.9-d21dd6ec05-cc0aae109e.zip +0 -0
- package/.yarn/cache/@types-normalize-package-data-npm-2.4.1-c31c56ae6a-e87bccbf11.zip +0 -0
- package/.yarn/cache/@types-normalize-path-npm-3.0.0-a1f250f88f-19f49b1cef.zip +0 -0
- package/.yarn/cache/@types-shelljs-npm-0.8.12-cbc88427ef-ffb47809ab.zip +0 -0
- package/.yarn/cache/abbrev-npm-1.1.1-3659247eab-a4a97ec07d.zip +0 -0
- package/.yarn/cache/acorn-npm-8.8.1-20e4aea981-4079b67283.zip +0 -0
- package/.yarn/cache/acorn-walk-npm-8.2.0-2f2cac3177-1715e76c01.zip +0 -0
- package/.yarn/cache/agent-base-npm-6.0.2-428f325a93-f52b6872cc.zip +0 -0
- package/.yarn/cache/agentkeepalive-npm-4.5.0-f237b580b2-13278cd5b1.zip +0 -0
- package/.yarn/cache/aggregate-error-npm-3.1.0-415a406f4e-1101a33f21.zip +0 -0
- package/.yarn/cache/ansi-regex-npm-5.0.1-c963a48615-2aa4bb54ca.zip +0 -0
- package/.yarn/cache/ansi-regex-npm-6.0.1-8d663a607d-1ff8b7667c.zip +0 -0
- package/.yarn/cache/ansi-styles-npm-3.2.1-8cb8107983-d85ade01c1.zip +0 -0
- package/.yarn/cache/ansi-styles-npm-4.3.0-245c7d42c7-513b44c3b2.zip +0 -0
- package/.yarn/cache/ansi-styles-npm-6.2.1-d43647018c-ef940f2f0c.zip +0 -0
- package/.yarn/cache/anymatch-npm-3.1.3-bc81d103b1-3e044fd6d1.zip +0 -0
- package/.yarn/cache/aproba-npm-2.0.0-8716bcfde6-5615cadcfb.zip +0 -0
- package/.yarn/cache/are-we-there-yet-npm-3.0.1-3395b1512f-52590c2486.zip +0 -0
- package/.yarn/cache/arg-npm-4.1.3-1748b966a8-544af8dd3f.zip +0 -0
- package/.yarn/cache/argparse-npm-1.0.10-528934e59d-7ca6e45583.zip +0 -0
- package/.yarn/cache/array-union-npm-2.1.0-4e4852b221-5bee12395c.zip +0 -0
- package/.yarn/cache/balanced-match-npm-1.0.2-a53c126459-9706c088a2.zip +0 -0
- package/.yarn/cache/base64-js-npm-1.5.1-b2f7275641-669632eb37.zip +0 -0
- package/.yarn/cache/before-after-hook-npm-2.2.3-d79e3d6608-a1a2430976.zip +0 -0
- package/.yarn/cache/big-integer-npm-1.6.51-1a244d8e1f-3d444173d1.zip +0 -0
- package/.yarn/cache/binary-extensions-npm-2.2.0-180c33fec7-ccd267956c.zip +0 -0
- package/.yarn/cache/binary-npm-0.3.0-56515cf10f-b4699fda9e.zip +0 -0
- package/.yarn/cache/bl-npm-4.1.0-7f94cdcf3f-9e8521fa7e.zip +0 -0
- package/.yarn/cache/bluebird-npm-3.4.7-5dff099581-bffa9dee7d.zip +0 -0
- package/.yarn/cache/brace-expansion-npm-1.1.11-fb95eb05ad-faf34a7bb0.zip +0 -0
- package/.yarn/cache/brace-expansion-npm-2.0.1-17aa2616f9-a61e7cd2e8.zip +0 -0
- package/.yarn/cache/braces-npm-3.0.2-782240b28a-e2a8e769a8.zip +0 -0
- package/.yarn/cache/buffer-indexof-polyfill-npm-1.0.2-39d49d63c8-fbfb2d69c6.zip +0 -0
- package/.yarn/cache/buffer-npm-5.7.1-513ef8259e-e2cf8429e1.zip +0 -0
- package/.yarn/cache/buffers-npm-0.1.1-59dbe6d7fb-ad6f8e483e.zip +0 -0
- package/.yarn/cache/cacache-npm-17.1.4-51ef53d0a8-b7751df756.zip +0 -0
- package/.yarn/cache/chainsaw-npm-0.1.0-0d34a3db01-22a96b9fb0.zip +0 -0
- package/.yarn/cache/chalk-npm-2.4.2-3ea16dd91e-ec3661d38f.zip +0 -0
- package/.yarn/cache/chalk-npm-4.1.2-ba8b67ab80-fe75c9d5c7.zip +0 -0
- package/.yarn/cache/chokidar-npm-3.5.3-c5f9b0a56a-b49fcde401.zip +0 -0
- package/.yarn/cache/chownr-npm-2.0.0-638f1c9c61-c57cf9dd07.zip +0 -0
- package/.yarn/cache/clean-stack-npm-2.2.0-a8ce435a5c-2ac8cd2b2f.zip +0 -0
- package/.yarn/cache/cli-cursor-npm-3.1.0-fee1e46b5e-2692784c6c.zip +0 -0
- package/.yarn/cache/cli-spinners-npm-2.7.0-ace95632f5-a9afaf73f5.zip +0 -0
- package/.yarn/cache/clone-npm-1.0.4-a610fcbcf9-d06418b733.zip +0 -0
- package/.yarn/cache/color-convert-npm-1.9.3-1fe690075e-fd7a64a17c.zip +0 -0
- package/.yarn/cache/color-convert-npm-2.0.1-79730e935b-79e6bdb9fd.zip +0 -0
- package/.yarn/cache/color-name-npm-1.1.3-728b7b5d39-09c5d3e33d.zip +0 -0
- package/.yarn/cache/color-name-npm-1.1.4-025792b0ea-b044585952.zip +0 -0
- package/.yarn/cache/color-support-npm-1.1.3-3be5c53455-9b73568176.zip +0 -0
- package/.yarn/cache/commander-npm-2.20.3-d8dcbaa39b-ab8c07884e.zip +0 -0
- package/.yarn/cache/commander-npm-5.1.0-7e939e7832-0b7fec1712.zip +0 -0
- package/.yarn/cache/commander-npm-9.4.1-9deffb2749-bfb18e325a.zip +0 -0
- package/.yarn/cache/concat-map-npm-0.0.1-85a921b7ee-902a9f5d89.zip +0 -0
- package/.yarn/cache/condense-newlines-npm-0.2.1-016452195f-3c20ff6ee8.zip +0 -0
- package/.yarn/cache/config-chain-npm-1.1.13-82e06afbc4-828137a28e.zip +0 -0
- package/.yarn/cache/console-control-strings-npm-1.1.0-e3160e5275-8755d76787.zip +0 -0
- package/.yarn/cache/core-util-is-npm-1.0.3-ca74b76c90-9de8597363.zip +0 -0
- package/.yarn/cache/create-require-npm-1.1.1-839884ca2e-a9a1503d43.zip +0 -0
- package/.yarn/cache/cross-spawn-npm-7.0.3-e4ff3e65b3-671cc7c728.zip +0 -0
- package/.yarn/cache/debug-npm-4.3.4-4513954577-3dbad3f94e.zip +0 -0
- package/.yarn/cache/deepmerge-npm-4.2.2-112165ced2-a8c43a1ed8.zip +0 -0
- package/.yarn/cache/defaults-npm-1.0.4-f3fbaf2528-3a88b7a587.zip +0 -0
- package/.yarn/cache/delegates-npm-1.0.0-9b1942d75f-a51744d9b5.zip +0 -0
- package/.yarn/cache/deprecation-npm-2.3.1-e19c92d6e7-f56a05e182.zip +0 -0
- package/.yarn/cache/detect-package-manager-npm-2.0.1-e5377363d9-e72b910182.zip +0 -0
- package/.yarn/cache/diff-npm-4.0.2-73133c7102-f2c09b0ce4.zip +0 -0
- package/.yarn/cache/dir-glob-npm-3.0.1-1aea628b1b-fa05e18324.zip +0 -0
- package/.yarn/cache/dom-serializer-npm-2.0.0-378ebc7200-cd1810544f.zip +0 -0
- package/.yarn/cache/domelementtype-npm-2.3.0-02de7cbfba-ee837a318f.zip +0 -0
- package/.yarn/cache/domhandler-npm-5.0.3-3ede73dc10-0f58f4a6af.zip +0 -0
- package/.yarn/cache/domutils-npm-3.0.1-7937818218-23aa7a8405.zip +0 -0
- package/.yarn/cache/duplexer2-npm-0.1.4-6bca6bef12-744961f03c.zip +0 -0
- package/.yarn/cache/eastasianwidth-npm-0.2.0-c37eb16bd1-7d00d7cd8e.zip +0 -0
- package/.yarn/cache/editorconfig-npm-0.15.3-873be190a7-a94afeda19.zip +0 -0
- package/.yarn/cache/emoji-regex-npm-8.0.0-213764015c-d4c5c39d5a.zip +0 -0
- package/.yarn/cache/emoji-regex-npm-9.2.2-e6fac8d058-8487182da7.zip +0 -0
- package/.yarn/cache/encoding-npm-0.1.13-82a1837d30-bb98632f8f.zip +0 -0
- package/.yarn/cache/entities-npm-4.4.0-97635dc5cc-84d250329f.zip +0 -0
- package/.yarn/cache/env-paths-npm-2.2.1-7c7577428c-65b5df55a8.zip +0 -0
- package/.yarn/cache/err-code-npm-2.0.3-082e0ff9a7-8b7b1be20d.zip +0 -0
- package/.yarn/cache/error-ex-npm-1.3.2-5654f80c0f-c1c2b8b65f.zip +0 -0
- package/.yarn/cache/esbuild-npm-0.16.4-ac3d3897e5-c06e9b2e84.zip +0 -0
- package/.yarn/cache/escape-string-regexp-npm-1.0.5-3284de402f-6092fda75c.zip +0 -0
- package/.yarn/cache/esprima-npm-4.0.1-1084e98778-b45bc805a6.zip +0 -0
- package/.yarn/cache/execa-npm-5.1.1-191347acf5-fba9022c8c.zip +0 -0
- package/.yarn/cache/exponential-backoff-npm-3.1.1-04df458b30-3d21519a4f.zip +0 -0
- package/.yarn/cache/extend-shallow-npm-2.0.1-e6ef52b29c-8fb58d9d7a.zip +0 -0
- package/.yarn/cache/fast-folder-size-npm-1.6.1-2b11f9e719-3e85cb5960.zip +0 -0
- package/.yarn/cache/fast-glob-npm-3.2.12-162763bbae-0b1990f6ce.zip +0 -0
- package/.yarn/cache/fastq-npm-1.13.0-a45963881c-32cf15c29a.zip +0 -0
- package/.yarn/cache/fill-range-npm-7.0.1-b8b1817caa-cc283f4e65.zip +0 -0
- package/.yarn/cache/find-up-npm-4.1.0-c3ccf8d855-4c172680e8.zip +0 -0
- package/.yarn/cache/foreground-child-npm-3.1.1-77e78ed774-139d270bc8.zip +0 -0
- package/.yarn/cache/fs-extra-npm-11.1.1-ca44602180-fb883c6824.zip +0 -0
- package/.yarn/cache/fs-extra-npm-8.1.0-197473387f-bf44f0e6ce.zip +0 -0
- package/.yarn/cache/fs-minipass-npm-2.1.0-501ef87306-1b8d128dae.zip +0 -0
- package/.yarn/cache/fs-minipass-npm-3.0.3-d148d6ac19-8722a41109.zip +0 -0
- package/.yarn/cache/fs.realpath-npm-1.0.0-c8f05d8126-99ddea01a7.zip +0 -0
- package/.yarn/cache/fsevents-npm-2.3.2-a881d6ac9f-97ade64e75.zip +0 -0
- package/.yarn/cache/fsevents-patch-2882183fbf-8.zip +0 -0
- package/.yarn/cache/fstream-npm-1.0.12-db27e8a713-e6998651ae.zip +0 -0
- package/.yarn/cache/function-bind-npm-1.1.1-b56b322ae9-b32fbaebb3.zip +0 -0
- package/.yarn/cache/gauge-npm-4.0.4-8f878385e9-788b6bfe52.zip +0 -0
- package/.yarn/cache/get-stream-npm-6.0.1-83e51a4642-e04ecece32.zip +0 -0
- package/.yarn/cache/glob-npm-10.3.9-a41b2187b4-806a4ef571.zip +0 -0
- package/.yarn/cache/glob-npm-7.2.3-2d866d17a5-29452e97b3.zip +0 -0
- package/.yarn/cache/glob-npm-8.0.3-750f909025-50bcdea19d.zip +0 -0
- package/.yarn/cache/glob-parent-npm-5.1.2-021ab32634-f4f2bfe242.zip +0 -0
- package/.yarn/cache/globby-npm-11.1.0-bdcdf20c71-b4be8885e0.zip +0 -0
- package/.yarn/cache/graceful-fs-npm-4.2.10-79c70989ca-3f109d70ae.zip +0 -0
- package/.yarn/cache/graceful-fs-npm-4.2.11-24bb648a68-ac85f94da9.zip +0 -0
- package/.yarn/cache/has-flag-npm-3.0.0-16ac11fe05-4a15638b45.zip +0 -0
- package/.yarn/cache/has-flag-npm-4.0.0-32af9f0536-261a135703.zip +0 -0
- package/.yarn/cache/has-npm-1.0.3-b7f00631c1-b9ad53d53b.zip +0 -0
- package/.yarn/cache/has-unicode-npm-2.0.1-893adb4747-1eab07a743.zip +0 -0
- package/.yarn/cache/hosted-git-info-npm-2.8.9-62c44fa93f-c955394bda.zip +0 -0
- package/.yarn/cache/html-to-text-npm-9.0.3-27f776e12e-4509edd5c0.zip +0 -0
- package/.yarn/cache/htmlparser2-npm-8.0.1-b432299617-06d5c71e83.zip +0 -0
- package/.yarn/cache/http-cache-semantics-npm-4.1.1-1120131375-83ac0bc60b.zip +0 -0
- package/.yarn/cache/http-proxy-agent-npm-5.0.0-7f1f121b83-e2ee1ff165.zip +0 -0
- package/.yarn/cache/https-proxy-agent-npm-5.0.1-42d65f358e-571fccdf38.zip +0 -0
- package/.yarn/cache/human-signals-npm-2.1.0-f75815481d-b87fd89fce.zip +0 -0
- package/.yarn/cache/humanize-ms-npm-1.2.1-e942bd7329-9c7a74a282.zip +0 -0
- package/.yarn/cache/iconv-lite-npm-0.6.3-24b8aae27e-3f60d47a5c.zip +0 -0
- package/.yarn/cache/ieee754-npm-1.2.1-fb63b3caeb-5144c0c981.zip +0 -0
- package/.yarn/cache/ignore-npm-5.2.1-208dc99ae8-7251d00cba.zip +0 -0
- package/.yarn/cache/imurmurhash-npm-0.1.4-610c5068a0-7cae75c8cd.zip +0 -0
- package/.yarn/cache/indent-string-npm-4.0.0-7b717435b2-824cfb9929.zip +0 -0
- package/.yarn/cache/inflight-npm-1.0.6-ccedb4b908-f4f76aa072.zip +0 -0
- package/.yarn/cache/inherits-npm-2.0.4-c66b3957a0-4a48a73384.zip +0 -0
- package/.yarn/cache/ini-npm-1.3.8-fb5040b4c0-dfd98b0ca3.zip +0 -0
- package/.yarn/cache/interpret-npm-1.4.0-17b4b5b0a4-2e5f51268b.zip +0 -0
- package/.yarn/cache/ip-npm-2.0.0-204facb3cc-cfcfac6b87.zip +0 -0
- package/.yarn/cache/is-arrayish-npm-0.2.1-23927dfb15-eef4417e3c.zip +0 -0
- package/.yarn/cache/is-binary-path-npm-2.1.0-e61d46f557-84192eb88c.zip +0 -0
- package/.yarn/cache/is-buffer-npm-1.1.6-08199d9ccc-4a186d995d.zip +0 -0
- package/.yarn/cache/is-core-module-npm-2.11.0-70061e141a-f96fd490c6.zip +0 -0
- package/.yarn/cache/is-extendable-npm-0.1.1-322b4649ec-3875571d20.zip +0 -0
- package/.yarn/cache/is-extglob-npm-2.1.1-0870ea68b5-df033653d0.zip +0 -0
- package/.yarn/cache/is-fullwidth-code-point-npm-3.0.0-1ecf4ebee5-44a30c2945.zip +0 -0
- package/.yarn/cache/is-glob-npm-4.0.3-cb87bf1bdb-d381c1319f.zip +0 -0
- package/.yarn/cache/is-interactive-npm-1.0.0-7ff7c6e04a-824808776e.zip +0 -0
- package/.yarn/cache/is-lambda-npm-1.0.1-7ab55bc8a8-93a32f0194.zip +0 -0
- package/.yarn/cache/is-number-npm-7.0.0-060086935c-456ac6f8e0.zip +0 -0
- package/.yarn/cache/is-plain-object-npm-5.0.0-285b70faa3-e32d27061e.zip +0 -0
- package/.yarn/cache/is-stream-npm-2.0.1-c802db55e7-b8e05ccdf9.zip +0 -0
- package/.yarn/cache/is-unicode-supported-npm-0.1.0-0833e1bbfb-a2aab86ee7.zip +0 -0
- package/.yarn/cache/is-whitespace-npm-0.3.0-994f2b3b8c-dac8fc9a9b.zip +0 -0
- package/.yarn/cache/isarray-npm-1.0.0-db4f547720-f032df8e02.zip +0 -0
- package/.yarn/cache/isexe-npm-2.0.0-b58870bd2e-26bf6c5480.zip +0 -0
- package/.yarn/cache/jackspeak-npm-2.3.5-c631837bc0-c2c211f13c.zip +0 -0
- package/.yarn/cache/jju-npm-1.4.0-670678eaa3-3790481bd2.zip +0 -0
- package/.yarn/cache/js-beautify-npm-1.14.7-31d479fd5c-1950d0d3f0.zip +0 -0
- package/.yarn/cache/js-tokens-npm-4.0.0-0ac852e9e2-8a95213a5a.zip +0 -0
- package/.yarn/cache/js-yaml-npm-3.14.1-b968c6095e-bef146085f.zip +0 -0
- package/.yarn/cache/json-parse-even-better-errors-npm-2.3.1-144d62256e-798ed4cf33.zip +0 -0
- package/.yarn/cache/jsonfile-npm-4.0.0-10ce3aea15-6447d6224f.zip +0 -0
- package/.yarn/cache/jsonfile-npm-6.1.0-20a4796cee-7af3b8e1ac.zip +0 -0
- package/.yarn/cache/kind-of-npm-3.2.2-7deaffa5f9-e898df8ca2.zip +0 -0
- package/.yarn/cache/leac-npm-0.6.0-79f7890bc5-a7a722cfc2.zip +0 -0
- package/.yarn/cache/lines-and-columns-npm-1.2.4-d6c7cc5799-0c37f9f7fa.zip +0 -0
- package/.yarn/cache/listenercount-npm-1.0.1-01172e4210-0f1c9077cd.zip +0 -0
- package/.yarn/cache/locate-path-npm-5.0.0-46580c43e4-83e51725e6.zip +0 -0
- package/.yarn/cache/log-symbols-npm-4.1.0-0a13492d8b-fce1497b31.zip +0 -0
- package/.yarn/cache/loose-envify-npm-1.4.0-6307b72ccf-6517e24e0c.zip +0 -0
- package/.yarn/cache/lru-cache-npm-10.0.1-0e1abf4c13-06f8d0e1ce.zip +0 -0
- package/.yarn/cache/lru-cache-npm-4.1.5-ede304cc43-4bb4b58a36.zip +0 -0
- package/.yarn/cache/lru-cache-npm-6.0.0-b4c8668fe1-f97f499f89.zip +0 -0
- package/.yarn/cache/lru-cache-npm-7.18.3-e68be5b11c-e550d77238.zip +0 -0
- package/.yarn/cache/make-error-npm-1.3.6-ccb85d9458-b86e5e0e25.zip +0 -0
- package/.yarn/cache/make-fetch-happen-npm-11.1.1-f32b79aaaa-7268bf274a.zip +0 -0
- package/.yarn/cache/merge-stream-npm-2.0.0-2ac83efea5-6fa4dcc8d8.zip +0 -0
- package/.yarn/cache/merge2-npm-1.4.1-a2507bd06c-7268db63ed.zip +0 -0
- package/.yarn/cache/micromatch-npm-4.0.5-cfab5d7669-02a17b671c.zip +0 -0
- package/.yarn/cache/mimic-fn-npm-2.1.0-4fbeb3abb4-d2421a3444.zip +0 -0
- package/.yarn/cache/minimatch-npm-3.1.2-9405269906-c154e56640.zip +0 -0
- package/.yarn/cache/minimatch-npm-5.1.1-521233e3d2-215edd0978.zip +0 -0
- package/.yarn/cache/minimatch-npm-9.0.3-69d7d6fad5-253487976b.zip +0 -0
- package/.yarn/cache/minimist-npm-1.2.7-51d33b1371-7346574a10.zip +0 -0
- package/.yarn/cache/minipass-collect-npm-1.0.2-3b4676eab5-14df761028.zip +0 -0
- package/.yarn/cache/minipass-fetch-npm-3.0.4-200ac7c66d-af7aad15d5.zip +0 -0
- package/.yarn/cache/minipass-flush-npm-1.0.5-efe79d9826-56269a0b22.zip +0 -0
- package/.yarn/cache/minipass-npm-3.3.6-b8d93a945b-a30d083c80.zip +0 -0
- package/.yarn/cache/minipass-npm-5.0.0-c64fb63c92-425dab2887.zip +0 -0
- package/.yarn/cache/minipass-npm-7.0.3-3b57909ee9-6f1614f5b5.zip +0 -0
- package/.yarn/cache/minipass-pipeline-npm-1.2.4-5924cb077f-b14240dac0.zip +0 -0
- package/.yarn/cache/minipass-sized-npm-1.0.3-306d86f432-79076749fc.zip +0 -0
- package/.yarn/cache/minizlib-npm-2.1.2-ea89cd0cfb-f1fdeac0b0.zip +0 -0
- package/.yarn/cache/mkdirp-npm-0.5.6-dcd5a6b97b-0c91b721bb.zip +0 -0
- package/.yarn/cache/mkdirp-npm-1.0.4-37f6ef56b9-a96865108c.zip +0 -0
- package/.yarn/cache/ms-npm-2.1.2-ec0c1512ff-673cdb2c31.zip +0 -0
- package/.yarn/cache/ms-npm-2.1.3-81ff3cfac1-aa92de6080.zip +0 -0
- package/.yarn/cache/negotiator-npm-0.6.3-9d50e36171-b8ffeb1e26.zip +0 -0
- package/.yarn/cache/node-fetch-npm-2.6.8-ddb8bfc274-91f57be68e.zip +0 -0
- package/.yarn/cache/node-gyp-npm-9.4.0-ebf5f5573e-78b404e2e0.zip +0 -0
- package/.yarn/cache/nopt-npm-6.0.0-5ea8050815-82149371f8.zip +0 -0
- package/.yarn/cache/normalize-package-data-npm-2.5.0-af0345deed-7999112efc.zip +0 -0
- package/.yarn/cache/normalize-path-npm-3.0.0-658ba7d77f-88eeb4da89.zip +0 -0
- package/.yarn/cache/npm-run-path-npm-4.0.1-7aebd8bab3-5374c0cea4.zip +0 -0
- package/.yarn/cache/npmlog-npm-6.0.2-e0e69455c7-ae238cd264.zip +0 -0
- package/.yarn/cache/once-npm-1.4.0-ccf03ef07a-cd0a885013.zip +0 -0
- package/.yarn/cache/onetime-npm-5.1.2-3ed148fa42-2478859ef8.zip +0 -0
- package/.yarn/cache/ora-npm-5.4.1-4f0343adb7-28d476ee6c.zip +0 -0
- package/.yarn/cache/p-limit-npm-2.3.0-94a0310039-84ff17f1a3.zip +0 -0
- package/.yarn/cache/p-locate-npm-4.1.0-eec6872537-513bd14a45.zip +0 -0
- package/.yarn/cache/p-map-npm-4.0.0-4677ae07c7-cb0ab21ec0.zip +0 -0
- package/.yarn/cache/p-try-npm-2.2.0-e0390dbaf8-f8a8e9a769.zip +0 -0
- package/.yarn/cache/parse-json-npm-5.2.0-00a63b1199-62085b17d6.zip +0 -0
- package/.yarn/cache/parseley-npm-0.11.0-5969ada3fb-cbd4762bf7.zip +0 -0
- package/.yarn/cache/path-exists-npm-4.0.0-e9e4f63eb0-505807199d.zip +0 -0
- package/.yarn/cache/path-is-absolute-npm-1.0.1-31bc695ffd-060840f92c.zip +0 -0
- package/.yarn/cache/path-key-npm-3.1.1-0e66ea8321-55cd7a9dd4.zip +0 -0
- package/.yarn/cache/path-parse-npm-1.0.7-09564527b7-49abf3d811.zip +0 -0
- package/.yarn/cache/path-scurry-npm-1.10.1-52bd946f2e-e2557cff3a.zip +0 -0
- package/.yarn/cache/path-type-npm-4.0.0-10d47fc86a-5b1e2daa24.zip +0 -0
- package/.yarn/cache/peberminta-npm-0.8.0-24ccdcb8be-77d8c02b70.zip +0 -0
- package/.yarn/cache/picomatch-npm-2.3.1-c782cfd986-050c865ce8.zip +0 -0
- package/.yarn/cache/pify-npm-4.0.1-062756097b-9c4e34278c.zip +0 -0
- package/.yarn/cache/prettier-npm-3.0.0-7ffbcce680-6a832876a1.zip +0 -0
- package/.yarn/cache/pretty-bytes-npm-5.6.0-0061079c9f-9c082500d1.zip +0 -0
- package/.yarn/cache/pretty-npm-2.0.0-9c25795870-9c41ae0559.zip +0 -0
- package/.yarn/cache/process-nextick-args-npm-2.0.1-b8d7971609-1d38588e52.zip +0 -0
- package/.yarn/cache/promise-retry-npm-2.0.1-871f0b01b7-f96a3f6d90.zip +0 -0
- package/.yarn/cache/proto-list-npm-1.2.4-a96a43df28-4d4826e171.zip +0 -0
- package/.yarn/cache/pseudomap-npm-1.0.2-0d0e40fee0-856c0aae0f.zip +0 -0
- package/.yarn/cache/queue-microtask-npm-1.2.3-fcc98e4e2d-b676f8c040.zip +0 -0
- package/.yarn/cache/react-dom-npm-18.2.0-dd675bca1c-7d323310be.zip +0 -0
- package/.yarn/cache/react-npm-18.2.0-1eae08fee2-88e38092da.zip +0 -0
- package/.yarn/cache/read-pkg-npm-5.2.0-50426bd8dc-eb696e6052.zip +0 -0
- package/.yarn/cache/read-yaml-file-npm-1.1.0-52eaf1c9d4-41ee5f0755.zip +0 -0
- package/.yarn/cache/readable-stream-npm-2.3.7-77b22a9818-e4920cf754.zip +0 -0
- package/.yarn/cache/readable-stream-npm-3.6.0-23a4a5eb56-d4ea81502d.zip +0 -0
- package/.yarn/cache/readable-stream-npm-3.6.2-d2a6069158-bdcbe6c22e.zip +0 -0
- package/.yarn/cache/readdirp-npm-3.6.0-f950cc74ab-1ced032e6e.zip +0 -0
- package/.yarn/cache/rechoir-npm-0.6.2-0df5f171ec-fe76bf9c21.zip +0 -0
- package/.yarn/cache/resolve-npm-1.22.1-3980488690-07af5fc1e8.zip +0 -0
- package/.yarn/cache/resolve-patch-0c52e0e4f7-5656f4d0be.zip +0 -0
- package/.yarn/cache/restore-cursor-npm-3.1.0-52c5a4c98f-f877dd8741.zip +0 -0
- package/.yarn/cache/retry-npm-0.12.0-72ac7fb4cc-623bd7d2e5.zip +0 -0
- package/.yarn/cache/reusify-npm-1.0.4-95ac4aec11-c3076ebcc2.zip +0 -0
- package/.yarn/cache/rimraf-npm-2.7.1-9a71f3cc37-cdc7f6eacb.zip +0 -0
- package/.yarn/cache/rimraf-npm-3.0.2-2cb7dac69a-87f4164e39.zip +0 -0
- package/.yarn/cache/run-parallel-npm-1.2.0-3f47ff2034-cb4f97ad25.zip +0 -0
- package/.yarn/cache/safe-buffer-npm-5.1.2-c27fedf6c4-f2f1f7943c.zip +0 -0
- package/.yarn/cache/safe-buffer-npm-5.2.1-3481c8aa9b-b99c4b41fd.zip +0 -0
- package/.yarn/cache/safer-buffer-npm-2.1.2-8d5c0b705e-cab8f25ae6.zip +0 -0
- package/.yarn/cache/scheduler-npm-0.23.0-a379a6bc3b-d79192eeaa.zip +0 -0
- package/.yarn/cache/selderee-npm-0.10.0-c753260073-8ecd535fe8.zip +0 -0
- package/.yarn/cache/semver-npm-5.7.1-40bcea106b-57fd0acfd0.zip +0 -0
- package/.yarn/cache/semver-npm-7.5.4-c4ad957fcd-12d8ad952f.zip +0 -0
- package/.yarn/cache/set-blocking-npm-2.0.0-49e2cffa24-6e65a05f7c.zip +0 -0
- package/.yarn/cache/setimmediate-npm-1.0.5-54587459b6-c9a6f2c5b5.zip +0 -0
- package/.yarn/cache/shebang-command-npm-2.0.0-eb2b01921d-6b52fe8727.zip +0 -0
- package/.yarn/cache/shebang-regex-npm-3.0.0-899a0cd65e-1a2bcae50d.zip +0 -0
- package/.yarn/cache/shelljs-npm-0.8.5-44be43f84a-7babc46f73.zip +0 -0
- package/.yarn/cache/sigmund-npm-1.0.1-c0417d7c57-793f81f808.zip +0 -0
- package/.yarn/cache/signal-exit-npm-3.0.7-bd270458a3-a2f098f247.zip +0 -0
- package/.yarn/cache/signal-exit-npm-4.1.0-61fb957687-64c757b498.zip +0 -0
- package/.yarn/cache/slash-npm-3.0.0-b87de2279a-94a93fff61.zip +0 -0
- package/.yarn/cache/smart-buffer-npm-4.2.0-5ac3f668bb-b5167a7142.zip +0 -0
- package/.yarn/cache/socks-npm-2.7.1-17f2b53052-259d9e3e8e.zip +0 -0
- package/.yarn/cache/socks-proxy-agent-npm-7.0.0-7aacf32ea0-7205543701.zip +0 -0
- package/.yarn/cache/spdx-correct-npm-3.1.1-47f574c27a-77ce438344.zip +0 -0
- package/.yarn/cache/spdx-exceptions-npm-2.3.0-2b68dad75a-cb69a26fa3.zip +0 -0
- package/.yarn/cache/spdx-expression-parse-npm-3.0.1-b718cbb35a-a1c6e104a2.zip +0 -0
- package/.yarn/cache/spdx-license-ids-npm-3.0.12-750216a0df-92a4dddce6.zip +0 -0
- package/.yarn/cache/sprintf-js-npm-1.0.3-73f0a322fa-19d79aec21.zip +0 -0
- package/.yarn/cache/ssri-npm-10.0.5-1a7557d04d-0a31b65f21.zip +0 -0
- package/.yarn/cache/string-width-npm-4.2.3-2c27177bae-e52c10dc3f.zip +0 -0
- package/.yarn/cache/string-width-npm-5.1.2-bf60531341-7369deaa29.zip +0 -0
- package/.yarn/cache/string_decoder-npm-1.1.1-e46a6c1353-9ab7e56f9d.zip +0 -0
- package/.yarn/cache/string_decoder-npm-1.3.0-2422117fd0-8417646695.zip +0 -0
- package/.yarn/cache/strip-ansi-npm-6.0.1-caddc7cb40-f3cd25890a.zip +0 -0
- package/.yarn/cache/strip-ansi-npm-7.1.0-7453b80b79-859c73fcf2.zip +0 -0
- package/.yarn/cache/strip-bom-npm-3.0.0-71e8f81ff9-8d50ff27b7.zip +0 -0
- package/.yarn/cache/strip-final-newline-npm-2.0.0-340c4f7c66-69412b5e25.zip +0 -0
- package/.yarn/cache/supports-color-npm-5.5.0-183ac537bc-95f6f4ba5a.zip +0 -0
- package/.yarn/cache/supports-color-npm-7.2.0-606bfcf7da-3dda818de0.zip +0 -0
- package/.yarn/cache/supports-preserve-symlinks-flag-npm-1.0.0-f17c4d0028-53b1e247e6.zip +0 -0
- package/.yarn/cache/tar-npm-6.2.0-3eb25205a7-db4d9fe74a.zip +0 -0
- package/.yarn/cache/to-regex-range-npm-5.0.1-f1e8263b00-f76fa01b3d.zip +0 -0
- package/.yarn/cache/tr46-npm-0.0.3-de53018915-726321c5ea.zip +0 -0
- package/.yarn/cache/traverse-npm-0.3.9-913743c694-982982e4e2.zip +0 -0
- package/.yarn/cache/tree-node-cli-npm-1.6.0-b1b47ddc09-205422ccca.zip +0 -0
- package/.yarn/cache/ts-node-npm-10.9.1-6c268be7f4-090adff130.zip +0 -0
- package/.yarn/cache/type-fest-npm-0.6.0-76b229965b-b2188e6e4b.zip +0 -0
- package/.yarn/cache/typescript-npm-5.1.6-b157762de3-b2f2c35096.zip +0 -0
- package/.yarn/cache/typescript-patch-bd21d74a9d-f53bfe97f7.zip +0 -0
- package/.yarn/cache/unique-filename-npm-3.0.0-77d68e0a45-8e2f59b356.zip +0 -0
- package/.yarn/cache/unique-slug-npm-4.0.0-e6b08f28aa-0884b58365.zip +0 -0
- package/.yarn/cache/universal-user-agent-npm-6.0.0-b148fb997a-5092bbc80d.zip +0 -0
- package/.yarn/cache/universalify-npm-0.1.2-9b22d31d2d-40cdc60f6e.zip +0 -0
- package/.yarn/cache/universalify-npm-2.0.0-03b8b418a8-2406a4edf4.zip +0 -0
- package/.yarn/cache/unzipper-npm-0.10.11-7a1d871174-006cd43ec4.zip +0 -0
- package/.yarn/cache/util-deprecate-npm-1.0.2-e3fe1a219c-474acf1146.zip +0 -0
- package/.yarn/cache/v8-compile-cache-lib-npm-3.0.1-4886071ece-78089ad549.zip +0 -0
- package/.yarn/cache/validate-npm-package-license-npm-3.0.4-7af8adc7a8-35703ac889.zip +0 -0
- package/.yarn/cache/wcwidth-npm-1.0.1-05fa596453-814e9d1ddc.zip +0 -0
- package/.yarn/cache/webidl-conversions-npm-3.0.1-60310f6a2b-c92a0a6ab9.zip +0 -0
- package/.yarn/cache/whatwg-url-npm-5.0.0-374fb45e60-b8daed4ad3.zip +0 -0
- package/.yarn/cache/which-npm-2.0.2-320ddf72f7-1a5c563d3c.zip +0 -0
- package/.yarn/cache/wide-align-npm-1.1.5-889d77e592-d5fc37cd56.zip +0 -0
- package/.yarn/cache/wrap-ansi-npm-7.0.0-ad6e1a0554-a790b846fd.zip +0 -0
- package/.yarn/cache/wrap-ansi-npm-8.1.0-26a4e6ae28-371733296d.zip +0 -0
- package/.yarn/cache/wrappy-npm-1.0.2-916de4d4b3-159da4805f.zip +0 -0
- package/.yarn/cache/yallist-npm-2.1.2-2e38c366a3-9ba9940920.zip +0 -0
- package/.yarn/cache/yallist-npm-4.0.0-b493d9e907-343617202a.zip +0 -0
- package/.yarn/cache/yn-npm-3.1.1-8ad4259784-2c487b0e14.zip +0 -0
- package/.yarn/install-state.gz +0 -0
package/.eslintrc.js
CHANGED
package/dist/package.json
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-email",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.10.0",
|
|
4
4
|
"description": "A live preview of your emails right in your browser.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"email": "./dist/source/index.js"
|
|
7
7
|
},
|
|
8
8
|
"types": "./dist/source/index.d.ts",
|
|
9
9
|
"scripts": {
|
|
10
|
-
"build": "tsc",
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"lint": "eslint",
|
|
14
|
-
"clean": "rm -rf dist"
|
|
10
|
+
"build": "tsc -p ./tsconfig.json",
|
|
11
|
+
"clean": "rm -rf dist",
|
|
12
|
+
"lint": "eslint ."
|
|
15
13
|
},
|
|
16
14
|
"license": "MIT",
|
|
17
15
|
"repository": {
|
|
@@ -24,33 +22,32 @@
|
|
|
24
22
|
"email"
|
|
25
23
|
],
|
|
26
24
|
"engines": {
|
|
27
|
-
"node": ">=
|
|
25
|
+
"node": ">=18.0.0"
|
|
28
26
|
},
|
|
29
27
|
"dependencies": {
|
|
30
28
|
"@commander-js/extra-typings": "9.4.1",
|
|
31
29
|
"@manypkg/find-root": "2.2.1",
|
|
32
30
|
"@octokit/rest": "19.0.7",
|
|
33
|
-
"@react-email/render": "0.0.
|
|
31
|
+
"@react-email/render": "0.0.10",
|
|
34
32
|
"chokidar": "3.5.3",
|
|
35
33
|
"commander": "9.4.1",
|
|
36
34
|
"detect-package-manager": "2.0.1",
|
|
37
35
|
"esbuild": "0.16.4",
|
|
38
36
|
"fs-extra": "11.1.1",
|
|
39
|
-
"glob": "
|
|
37
|
+
"glob": "10.3.4",
|
|
40
38
|
"log-symbols": "4.1.0",
|
|
41
39
|
"normalize-path": "3.0.0",
|
|
42
40
|
"ora": "5.4.1",
|
|
43
41
|
"read-pkg": "5.2.0",
|
|
44
42
|
"shelljs": "0.8.5",
|
|
45
|
-
"tree-
|
|
43
|
+
"tree-cli": "0.6.7"
|
|
46
44
|
},
|
|
47
45
|
"devDependencies": {
|
|
48
46
|
"@types/fs-extra": "11.0.1",
|
|
49
|
-
"@types/node": "18.11.9",
|
|
50
47
|
"@types/normalize-path": "3.0.0",
|
|
51
48
|
"@types/shelljs": "0.8.12",
|
|
52
|
-
"
|
|
53
|
-
"
|
|
49
|
+
"eslint-config-custom": "workspace:*",
|
|
50
|
+
"tsconfig": "workspace:*",
|
|
54
51
|
"typescript": "5.1.6"
|
|
55
52
|
}
|
|
56
53
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dev.d.ts","sourceRoot":"","sources":["../../../source/commands/dev.ts"],"names":[],"mappings":"AAKA,UAAU,IAAI;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,OAAO,CAAC;CACtB;AAED,eAAO,MAAM,GAAG,+BAAsC,IAAI,kBAkBzD,CAAC"}
|
|
@@ -1,28 +1,80 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
2
38
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
39
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
40
|
};
|
|
5
41
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
42
|
exports.dev = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
43
|
+
var node_fs_1 = __importDefault(require("node:fs"));
|
|
44
|
+
var shelljs_1 = __importDefault(require("shelljs"));
|
|
45
|
+
var utils_1 = require("../utils");
|
|
46
|
+
var run_server_1 = require("../utils/run-server");
|
|
47
|
+
var dev = function (_a) {
|
|
48
|
+
var dir = _a.dir, port = _a.port, skipInstall = _a.skipInstall;
|
|
49
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
50
|
+
var error_1;
|
|
51
|
+
return __generator(this, function (_b) {
|
|
52
|
+
switch (_b.label) {
|
|
53
|
+
case 0:
|
|
54
|
+
_b.trys.push([0, 5, , 6]);
|
|
55
|
+
if (!node_fs_1.default.existsSync(dir)) {
|
|
56
|
+
throw new Error("Missing ".concat(dir, " folder"));
|
|
57
|
+
}
|
|
58
|
+
if (!node_fs_1.default.existsSync(utils_1.REACT_EMAIL_ROOT)) return [3 /*break*/, 2];
|
|
59
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('dev', dir, port, skipInstall)];
|
|
60
|
+
case 1:
|
|
61
|
+
_b.sent();
|
|
62
|
+
return [2 /*return*/];
|
|
63
|
+
case 2: return [4 /*yield*/, (0, utils_1.downloadClient)()];
|
|
64
|
+
case 3:
|
|
65
|
+
_b.sent();
|
|
66
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('dev', dir, port, skipInstall)];
|
|
67
|
+
case 4:
|
|
68
|
+
_b.sent();
|
|
69
|
+
return [3 /*break*/, 6];
|
|
70
|
+
case 5:
|
|
71
|
+
error_1 = _b.sent();
|
|
72
|
+
console.log(error_1);
|
|
73
|
+
shelljs_1.default.exit(1);
|
|
74
|
+
return [3 /*break*/, 6];
|
|
75
|
+
case 6: return [2 /*return*/];
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
});
|
|
27
79
|
};
|
|
28
80
|
exports.dev = dev;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../../source/commands/export.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAWnD,eAAO,MAAM,eAAe,WAClB,MAAM,UACN,MAAM,WACL,OAAO,mBA0FjB,CAAC"}
|
|
@@ -22,73 +22,153 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
22
22
|
__setModuleDefault(result, mod);
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
26
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
27
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
28
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
29
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
30
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
31
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
35
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
36
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
37
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
38
|
+
function step(op) {
|
|
39
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
40
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
41
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
42
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
43
|
+
switch (op[0]) {
|
|
44
|
+
case 0: case 1: t = op; break;
|
|
45
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
46
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
47
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
48
|
+
default:
|
|
49
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
50
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
51
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
52
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
53
|
+
if (t[2]) _.ops.pop();
|
|
54
|
+
_.trys.pop(); continue;
|
|
55
|
+
}
|
|
56
|
+
op = body.call(thisArg, _);
|
|
57
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
58
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
59
|
+
}
|
|
60
|
+
};
|
|
25
61
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
62
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
63
|
};
|
|
28
64
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
65
|
exports.exportTemplates = void 0;
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
const close_ora_on_sigint_1 = require("../utils/close-ora-on-sigint");
|
|
66
|
+
var node_fs_1 = __importStar(require("node:fs"));
|
|
67
|
+
var node_path_1 = __importDefault(require("node:path"));
|
|
68
|
+
var glob_1 = require("glob");
|
|
69
|
+
var esbuild_1 = __importDefault(require("esbuild"));
|
|
70
|
+
var ora_1 = __importDefault(require("ora"));
|
|
71
|
+
var log_symbols_1 = __importDefault(require("log-symbols"));
|
|
72
|
+
var render_1 = require("@react-email/render");
|
|
73
|
+
var normalize_path_1 = __importDefault(require("normalize-path"));
|
|
74
|
+
var shelljs_1 = __importDefault(require("shelljs"));
|
|
75
|
+
var close_ora_on_sigint_1 = require("../utils/close-ora-on-sigint");
|
|
76
|
+
var tree_1 = require("../utils/tree");
|
|
42
77
|
/*
|
|
43
78
|
This first builds all the templates using esbuild and then puts the output in the `.js`
|
|
44
79
|
files. Then these `.js` files are imported dynamically and rendered to `.html` files
|
|
45
80
|
using the `render` function.
|
|
46
81
|
*/
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
(
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
82
|
+
var exportTemplates = function (outDir, srcDir, options) { return __awaiter(void 0, void 0, void 0, function () {
|
|
83
|
+
var spinner, allTemplates, buildResult, allBuiltTemplates, _i, allBuiltTemplates_1, template, component, rendered, htmlPath, exception_1, staticDir, hasStaticDirectory, result, fileTree;
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
switch (_a.label) {
|
|
86
|
+
case 0:
|
|
87
|
+
spinner = (0, ora_1.default)('Preparing files...\n').start();
|
|
88
|
+
(0, close_ora_on_sigint_1.closeOraOnSIGNIT)(spinner);
|
|
89
|
+
allTemplates = glob_1.glob.sync((0, normalize_path_1.default)(node_path_1.default.join(srcDir, '*.{tsx,jsx}')));
|
|
90
|
+
buildResult = esbuild_1.default.buildSync({
|
|
91
|
+
bundle: true,
|
|
92
|
+
entryPoints: allTemplates,
|
|
93
|
+
platform: 'node',
|
|
94
|
+
write: true,
|
|
95
|
+
tsconfig: node_path_1.default.join(__dirname, '../../..', 'tsconfig.export.json'),
|
|
96
|
+
outdir: outDir,
|
|
97
|
+
});
|
|
98
|
+
if (buildResult.warnings.length > 0) {
|
|
99
|
+
console.warn(buildResult.warnings);
|
|
100
|
+
}
|
|
101
|
+
if (buildResult.errors.length > 0) {
|
|
102
|
+
spinner.stopAndPersist({
|
|
103
|
+
symbol: log_symbols_1.default.error,
|
|
104
|
+
text: 'Failed to build emails',
|
|
105
|
+
});
|
|
106
|
+
console.error(buildResult.errors);
|
|
107
|
+
throw new Error("esbuild bundling process for email templates:\n".concat(allTemplates
|
|
108
|
+
.map(function (p) { return "- ".concat(p); })
|
|
109
|
+
.join('\n')));
|
|
110
|
+
}
|
|
111
|
+
spinner.succeed();
|
|
112
|
+
allBuiltTemplates = glob_1.glob.sync((0, normalize_path_1.default)("".concat(outDir, "/*.js")), {
|
|
113
|
+
absolute: true,
|
|
114
|
+
});
|
|
115
|
+
_i = 0, allBuiltTemplates_1 = allBuiltTemplates;
|
|
116
|
+
_a.label = 1;
|
|
117
|
+
case 1:
|
|
118
|
+
if (!(_i < allBuiltTemplates_1.length)) return [3 /*break*/, 6];
|
|
119
|
+
template = allBuiltTemplates_1[_i];
|
|
120
|
+
_a.label = 2;
|
|
121
|
+
case 2:
|
|
122
|
+
_a.trys.push([2, 4, , 5]);
|
|
123
|
+
spinner.text = "rendering ".concat(template.split('/').pop());
|
|
124
|
+
spinner.render();
|
|
125
|
+
return [4 /*yield*/, Promise.resolve("".concat(template)).then(function (s) { return __importStar(require(s)); })];
|
|
126
|
+
case 3:
|
|
127
|
+
component = _a.sent();
|
|
128
|
+
rendered = (0, render_1.render)(component.default({}), options);
|
|
129
|
+
htmlPath = template.replace('.js', options.plainText ? '.txt' : '.html');
|
|
130
|
+
(0, node_fs_1.writeFileSync)(htmlPath, rendered);
|
|
131
|
+
(0, node_fs_1.unlinkSync)(template);
|
|
132
|
+
return [3 /*break*/, 5];
|
|
133
|
+
case 4:
|
|
134
|
+
exception_1 = _a.sent();
|
|
135
|
+
spinner.stopAndPersist({
|
|
136
|
+
symbol: log_symbols_1.default.error,
|
|
137
|
+
text: "failed when rendering ".concat(template.split('/').pop()),
|
|
138
|
+
});
|
|
139
|
+
console.error(exception_1);
|
|
140
|
+
throw exception_1;
|
|
141
|
+
case 5:
|
|
142
|
+
_i++;
|
|
143
|
+
return [3 /*break*/, 1];
|
|
144
|
+
case 6:
|
|
145
|
+
spinner.succeed('Rendered all files');
|
|
146
|
+
spinner.text = "Copying static files";
|
|
147
|
+
spinner.render();
|
|
148
|
+
staticDir = node_path_1.default.join(srcDir, 'static');
|
|
149
|
+
hasStaticDirectory = node_fs_1.default.existsSync(staticDir);
|
|
150
|
+
if (hasStaticDirectory) {
|
|
151
|
+
result = shelljs_1.default.cp('-r', staticDir, node_path_1.default.join(outDir, 'static'));
|
|
152
|
+
if (result.code > 0) {
|
|
153
|
+
spinner.stopAndPersist({
|
|
154
|
+
symbol: log_symbols_1.default.error,
|
|
155
|
+
text: 'Failed to copy static files',
|
|
156
|
+
});
|
|
157
|
+
throw new Error("Something went wrong while copying the file to ".concat(outDir, "/static, ").concat(result.cat()));
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
spinner.succeed();
|
|
161
|
+
return [4 /*yield*/, (0, tree_1.tree)(outDir, 4)];
|
|
162
|
+
case 7:
|
|
163
|
+
fileTree = _a.sent();
|
|
164
|
+
console.log(fileTree);
|
|
165
|
+
spinner.stopAndPersist({
|
|
166
|
+
symbol: log_symbols_1.default.success,
|
|
167
|
+
text: 'Successfully exported emails',
|
|
168
|
+
});
|
|
169
|
+
process.exit();
|
|
170
|
+
return [2 /*return*/];
|
|
80
171
|
}
|
|
81
|
-
}
|
|
82
|
-
spinner.succeed();
|
|
83
|
-
const fileTree = (0, tree_node_cli_1.default)(outDir, {
|
|
84
|
-
allFiles: true,
|
|
85
|
-
maxDepth: 4,
|
|
86
172
|
});
|
|
87
|
-
|
|
88
|
-
spinner.stopAndPersist({
|
|
89
|
-
symbol: log_symbols_1.default.success,
|
|
90
|
-
text: 'Successfully exported emails',
|
|
91
|
-
});
|
|
92
|
-
process.exit();
|
|
93
|
-
};
|
|
173
|
+
}); };
|
|
94
174
|
exports.exportTemplates = exportTemplates;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preview.d.ts","sourceRoot":"","sources":["../../../source/commands/preview.ts"],"names":[],"mappings":"AAKA,UAAU,gBAAgB;IACxB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,eAAO,MAAM,YAAY,YAAmB,gBAAgB,kBAc3D,CAAC;AAEF,UAAU,gBAAgB;IACxB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,eAAO,MAAM,YAAY,aAAoB,gBAAgB,kBAc5D,CAAC"}
|
|
@@ -1,40 +1,108 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
2
38
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
39
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
40
|
};
|
|
5
41
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
42
|
exports.startPreview = exports.buildPreview = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
43
|
+
var node_fs_1 = __importDefault(require("node:fs"));
|
|
44
|
+
var shelljs_1 = __importDefault(require("shelljs"));
|
|
45
|
+
var utils_1 = require("../utils");
|
|
46
|
+
var run_server_1 = require("../utils/run-server");
|
|
47
|
+
var buildPreview = function (_a) {
|
|
48
|
+
var dir = _a.dir;
|
|
49
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
50
|
+
var error_1;
|
|
51
|
+
return __generator(this, function (_b) {
|
|
52
|
+
switch (_b.label) {
|
|
53
|
+
case 0:
|
|
54
|
+
_b.trys.push([0, 5, , 6]);
|
|
55
|
+
if (!node_fs_1.default.existsSync(utils_1.REACT_EMAIL_ROOT)) return [3 /*break*/, 2];
|
|
56
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('build', dir, '')];
|
|
57
|
+
case 1:
|
|
58
|
+
_b.sent();
|
|
59
|
+
return [2 /*return*/];
|
|
60
|
+
case 2: return [4 /*yield*/, (0, utils_1.downloadClient)()];
|
|
61
|
+
case 3:
|
|
62
|
+
_b.sent();
|
|
63
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('build', dir, '')];
|
|
64
|
+
case 4:
|
|
65
|
+
_b.sent();
|
|
66
|
+
return [3 /*break*/, 6];
|
|
67
|
+
case 5:
|
|
68
|
+
error_1 = _b.sent();
|
|
69
|
+
console.log(error_1);
|
|
70
|
+
shelljs_1.default.exit(1);
|
|
71
|
+
return [3 /*break*/, 6];
|
|
72
|
+
case 6: return [2 /*return*/];
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
});
|
|
24
76
|
};
|
|
25
77
|
exports.buildPreview = buildPreview;
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
78
|
+
var startPreview = function (_a) {
|
|
79
|
+
var port = _a.port;
|
|
80
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
81
|
+
var error_2;
|
|
82
|
+
return __generator(this, function (_b) {
|
|
83
|
+
switch (_b.label) {
|
|
84
|
+
case 0:
|
|
85
|
+
_b.trys.push([0, 5, , 6]);
|
|
86
|
+
if (!node_fs_1.default.existsSync(utils_1.REACT_EMAIL_ROOT)) return [3 /*break*/, 2];
|
|
87
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('start', '', port)];
|
|
88
|
+
case 1:
|
|
89
|
+
_b.sent();
|
|
90
|
+
return [2 /*return*/];
|
|
91
|
+
case 2: return [4 /*yield*/, (0, utils_1.downloadClient)()];
|
|
92
|
+
case 3:
|
|
93
|
+
_b.sent();
|
|
94
|
+
return [4 /*yield*/, (0, run_server_1.setupServer)('start', '', port)];
|
|
95
|
+
case 4:
|
|
96
|
+
_b.sent();
|
|
97
|
+
return [3 /*break*/, 6];
|
|
98
|
+
case 5:
|
|
99
|
+
error_2 = _b.sent();
|
|
100
|
+
console.log(error_2);
|
|
101
|
+
shelljs_1.default.exit(1);
|
|
102
|
+
return [3 /*break*/, 6];
|
|
103
|
+
case 6: return [2 /*return*/];
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
});
|
|
39
107
|
};
|
|
40
108
|
exports.startPreview = startPreview;
|
package/dist/source/index.d.ts
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../source/index.ts"],"names":[],"mappings":""}
|
package/dist/source/index.js
CHANGED
|
@@ -4,12 +4,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
5
|
};
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
var extra_typings_1 = require("@commander-js/extra-typings");
|
|
9
|
+
var package_json_1 = __importDefault(require("../package.json"));
|
|
10
|
+
var dev_1 = require("./commands/dev");
|
|
11
|
+
var preview_1 = require("./commands/preview");
|
|
12
|
+
var export_1 = require("./commands/export");
|
|
13
|
+
var constants_1 = require("./utils/constants");
|
|
13
14
|
extra_typings_1.program
|
|
14
15
|
.name(constants_1.PACKAGE_NAME)
|
|
15
16
|
.description('A live preview of your emails right in your browser')
|
|
@@ -38,5 +39,8 @@ extra_typings_1.program
|
|
|
38
39
|
.option('-p, --pretty', 'Pretty print the output', false)
|
|
39
40
|
.option('-t, --plainText', 'Set output format as plain text', false)
|
|
40
41
|
.option('-d, --dir <path>', 'Directory with your email templates', './emails')
|
|
41
|
-
.action(
|
|
42
|
+
.action(function (_a) {
|
|
43
|
+
var outDir = _a.outDir, pretty = _a.pretty, plainText = _a.plainText, srcDir = _a.dir;
|
|
44
|
+
return (0, export_1.exportTemplates)(outDir, srcDir, { pretty: pretty, plainText: plainText });
|
|
45
|
+
});
|
|
42
46
|
extra_typings_1.program.parse();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"close-ora-on-sigint.d.ts","sourceRoot":"","sources":["../../../source/utils/close-ora-on-sigint.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE/B,eAAO,MAAM,gBAAgB,YAAa,GAAG,SAI5C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../source/utils/constants.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,wBAAwB,WAAW,CAAC;AACjD,eAAO,MAAM,YAAY,gBAAgB,CAAC;AAG1C,eAAO,MAAM,YAAY,QAAgB,CAAC;AAG1C,eAAO,MAAM,iBAAiB,QAA0C,CAAC;AACzE,eAAO,MAAM,iBAAiB,QAA8C,CAAC;AAG7E,eAAO,MAAM,gBAAgB,QAA0C,CAAC;AAGxE,eAAO,MAAM,kBAAkB,WAAW,CAAC;AAE3C,eAAO,MAAM,mBAAmB,QAG/B,CAAC;AAEF,eAAO,MAAM,mBAAmB,QAAwC,CAAC"}
|