@remotion/bundler 4.0.0-preload.13 → 4.0.0-publish.3
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/dist/bundle-mode.d.ts +1 -1
- package/dist/bundle.d.ts +6 -6
- package/dist/bundle.js +3 -3
- package/dist/dev-middleware/compatible-api.d.ts +1 -0
- package/dist/dev-middleware/is-color-supported.js +5 -1
- package/dist/error-overlay/react-overlay/utils/open-in-editor.js +5 -1
- package/dist/error-overlay/remotion-overlay/AskOnDiscord.js +1 -1
- package/dist/error-overlay/remotion-overlay/Button.js +1 -1
- package/dist/error-overlay/remotion-overlay/CodeFrame.js +2 -2
- package/dist/error-overlay/remotion-overlay/DismissButton.js +1 -1
- package/dist/error-overlay/remotion-overlay/ErrorDisplay.js +2 -2
- package/dist/error-overlay/remotion-overlay/ErrorLoader.js +4 -4
- package/dist/error-overlay/remotion-overlay/ErrorTitle.js +1 -1
- package/dist/error-overlay/remotion-overlay/OpenInEditor.js +1 -1
- package/dist/error-overlay/remotion-overlay/Overlay.js +1 -1
- package/dist/error-overlay/remotion-overlay/SearchGitHubIssues.js +1 -1
- package/dist/error-overlay/remotion-overlay/StackFrame.js +2 -2
- package/dist/error-overlay/remotion-overlay/Symbolicating.js +1 -1
- package/dist/error-overlay/remotion-overlay/carets.d.ts +1 -0
- package/dist/error-overlay/remotion-overlay/carets.js +2 -2
- package/dist/error-overlay/remotion-overlay/index.js +2 -2
- package/dist/esbuild-loader/index.d.ts +2 -2
- package/dist/esbuild-loader/index.js +1 -0
- package/dist/esbuild-loader/interfaces.d.ts +1 -1
- package/dist/fast-refresh/index.d.ts +1 -1
- package/dist/fast-refresh/index.js +0 -27
- package/dist/fast-refresh/loader.d.ts +1 -1
- package/dist/get-port.js +26 -24
- package/dist/homepage/homepage.d.ts +0 -1
- package/dist/homepage/homepage.js +5 -6
- package/dist/hot-middleware/process-update.js +2 -2
- package/dist/index-html.d.ts +1 -0
- package/dist/index-html.js +44 -0
- package/dist/index.d.ts +17 -17
- package/dist/index.js +8 -9
- package/dist/is-path-inside.d.ts +1 -0
- package/dist/is-path-inside.js +27 -0
- package/dist/p-limit.d.ts +1 -0
- package/dist/p-limit.js +57 -0
- package/dist/renderEntry.d.ts +1 -1
- package/dist/renderEntry.js +51 -38
- package/dist/routes.d.ts +2 -0
- package/dist/routes.js +121 -0
- package/dist/serve-static.d.ts +9 -0
- package/dist/serve-static.js +81 -0
- package/dist/start-server-pure.d.ts +8 -0
- package/dist/start-server-pure.js +68 -0
- package/dist/start-server.d.ts +6 -6
- package/dist/start-server.js +4 -4
- package/dist/ts-alias-plugin.d.ts +4 -0
- package/dist/ts-alias-plugin.js +21 -0
- package/dist/webpack-cache.d.ts +3 -3
- package/dist/webpack-cache.js +8 -12
- package/dist/webpack-config.d.ts +3 -3
- package/dist/webpack-config.js +12 -23
- package/package.json +5 -19
- package/web/favicon.png +0 -0
package/dist/bundle-mode.d.ts
CHANGED
package/dist/bundle.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { WebpackOverrideFn } from 'remotion';
|
|
1
|
+
import type { WebpackOverrideFn } from 'remotion';
|
|
2
2
|
export declare const bundle: (entryPoint: string, onProgressUpdate?: ((progress: number) => void) | undefined, options?: {
|
|
3
|
-
webpackOverride?: WebpackOverrideFn
|
|
4
|
-
outDir?: string
|
|
5
|
-
enableCaching?: boolean
|
|
6
|
-
publicPath?: string
|
|
7
|
-
}
|
|
3
|
+
webpackOverride?: WebpackOverrideFn;
|
|
4
|
+
outDir?: string;
|
|
5
|
+
enableCaching?: boolean;
|
|
6
|
+
publicPath?: string;
|
|
7
|
+
}) => Promise<string>;
|
package/dist/bundle.js
CHANGED
|
@@ -11,7 +11,7 @@ const remotion_1 = require("remotion");
|
|
|
11
11
|
const util_1 = require("util");
|
|
12
12
|
const webpack_1 = __importDefault(require("webpack"));
|
|
13
13
|
const copy_dir_1 = require("./copy-dir");
|
|
14
|
-
const
|
|
14
|
+
const index_html_1 = require("./index-html");
|
|
15
15
|
const webpack_config_1 = require("./webpack-config");
|
|
16
16
|
const entry = require.resolve('./renderEntry');
|
|
17
17
|
const promisified = (0, util_1.promisify)(webpack_1.default);
|
|
@@ -49,7 +49,7 @@ const bundle = async (entryPoint, onProgressUpdate, options) => {
|
|
|
49
49
|
maxTimelineTracks: 15,
|
|
50
50
|
// For production, the variables are set dynamically
|
|
51
51
|
envVariables: {},
|
|
52
|
-
|
|
52
|
+
entryPoints: [],
|
|
53
53
|
}),
|
|
54
54
|
]);
|
|
55
55
|
if (!output) {
|
|
@@ -69,7 +69,7 @@ const bundle = async (entryPoint, onProgressUpdate, options) => {
|
|
|
69
69
|
if (fs_1.default.existsSync(from)) {
|
|
70
70
|
await (0, copy_dir_1.copyDir)(from, to);
|
|
71
71
|
}
|
|
72
|
-
const html = (0,
|
|
72
|
+
const html = (0, index_html_1.indexHtml)(publicDir, baseDir, null, null);
|
|
73
73
|
fs_1.default.writeFileSync(path_1.default.join(outDir, 'index.html'), html);
|
|
74
74
|
return outDir;
|
|
75
75
|
};
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
|
@@ -2,7 +2,11 @@
|
|
|
2
2
|
// Duplicated in create-video/src/open-in-editor.ts
|
|
3
3
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
4
|
if (k2 === undefined) k2 = k;
|
|
5
|
-
Object.
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
6
10
|
}) : (function(o, m, k, k2) {
|
|
7
11
|
if (k2 === undefined) k2 = k;
|
|
8
12
|
o[k2] = m[k];
|
|
@@ -9,6 +9,6 @@ const AskOnDiscord = () => {
|
|
|
9
9
|
const openInBrowser = (0, react_1.useCallback)(() => {
|
|
10
10
|
window.open(DISCORD_LINK, '_blank');
|
|
11
11
|
}, []);
|
|
12
|
-
return (0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, children: "Ask on Discord" }
|
|
12
|
+
return (0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, children: "Ask on Discord" });
|
|
13
13
|
};
|
|
14
14
|
exports.AskOnDiscord = AskOnDiscord;
|
|
@@ -19,6 +19,6 @@ const buttonContainer = {
|
|
|
19
19
|
fontSize: 14,
|
|
20
20
|
};
|
|
21
21
|
const Button = ({ children, onClick, disabled }) => {
|
|
22
|
-
return ((0, jsx_runtime_1.jsx)("button", { style: button, type: "button", disabled: disabled, onClick: onClick, children: (0, jsx_runtime_1.jsx)("div", { style: buttonContainer, children: children }
|
|
22
|
+
return ((0, jsx_runtime_1.jsx)("button", { style: button, type: "button", disabled: disabled, onClick: onClick, children: (0, jsx_runtime_1.jsx)("div", { style: buttonContainer, children: children }) }));
|
|
23
23
|
};
|
|
24
24
|
exports.Button = Button;
|
|
@@ -22,7 +22,7 @@ const CodeFrame = ({ source, lineNumberWidth }) => {
|
|
|
22
22
|
tabSize: 2,
|
|
23
23
|
color: s.highlight ? 'white' : 'rgba(255, 255, 255, 0.6)',
|
|
24
24
|
lineHeight: 1.7,
|
|
25
|
-
}, children: [(0, jsx_runtime_1.jsx)("div", { style: lineNumber, children: String(s.lineNumber).padStart(lineNumberWidth, ' ') }
|
|
26
|
-
}) }
|
|
25
|
+
}, children: [(0, jsx_runtime_1.jsx)("div", { style: lineNumber, children: String(s.lineNumber).padStart(lineNumberWidth, ' ') }), s.content] }, j));
|
|
26
|
+
}) }));
|
|
27
27
|
};
|
|
28
28
|
exports.CodeFrame = CodeFrame;
|
|
@@ -18,6 +18,6 @@ const DismissButton = () => {
|
|
|
18
18
|
const dismiss = (0, react_1.useCallback)(() => {
|
|
19
19
|
window.location.href = '/';
|
|
20
20
|
}, []);
|
|
21
|
-
return ((0, jsx_runtime_1.jsx)("button", { type: "button", style: style, onClick: dismiss, children: (0, jsx_runtime_1.jsx)("svg", { focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 352 512", style: size, children: (0, jsx_runtime_1.jsx)("path", { fill: "white", d: "M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z" }
|
|
21
|
+
return ((0, jsx_runtime_1.jsx)("button", { type: "button", style: style, onClick: dismiss, children: (0, jsx_runtime_1.jsx)("svg", { focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 352 512", style: size, children: (0, jsx_runtime_1.jsx)("path", { fill: "white", d: "M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z" }) }) }));
|
|
22
22
|
};
|
|
23
23
|
exports.DismissButton = DismissButton;
|
|
@@ -36,10 +36,10 @@ const ErrorDisplay = ({ display }) => {
|
|
|
36
36
|
.trim();
|
|
37
37
|
}, [display.error]);
|
|
38
38
|
const lineNumberWidth = String(highestLineNumber).length;
|
|
39
|
-
return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: display.error.name, message: message }
|
|
39
|
+
return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: display.error.name, message: message }), display.stackFrames.length > 0 && window.remotion_editorName ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(OpenInEditor_1.OpenInEditor, { stack: display.stackFrames[0] }), (0, jsx_runtime_1.jsx)("div", { style: spacer })] })) : null, (0, jsx_runtime_1.jsx)(SearchGitHubIssues_1.SearchGithubIssues, { message: display.error.message }), (0, jsx_runtime_1.jsx)("div", { style: spacer }), (0, jsx_runtime_1.jsx)(AskOnDiscord_1.AskOnDiscord, {}), (0, jsx_runtime_1.jsx)("div", { style: stack, children: display.stackFrames.map((s, i) => {
|
|
40
40
|
return ((0, jsx_runtime_1.jsx)(StackFrame_1.StackElement
|
|
41
41
|
// eslint-disable-next-line react/no-array-index-key
|
|
42
42
|
, { isFirst: i === 0, s: s, lineNumberWidth: lineNumberWidth, defaultFunctionName: '(anonymous function)' }, i));
|
|
43
|
-
}) }
|
|
43
|
+
}) })] }));
|
|
44
44
|
};
|
|
45
45
|
exports.ErrorDisplay = ErrorDisplay;
|
|
@@ -48,14 +48,14 @@ const ErrorLoader = ({ error }) => {
|
|
|
48
48
|
});
|
|
49
49
|
}, [error]);
|
|
50
50
|
if (state.type === 'loading') {
|
|
51
|
-
return ((0, jsx_runtime_1.jsx)("div", { style: container, children: (0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: true, name: error.name, message: error.message }
|
|
51
|
+
return ((0, jsx_runtime_1.jsx)("div", { style: container, children: (0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: true, name: error.name, message: error.message }) }));
|
|
52
52
|
}
|
|
53
53
|
if (state.type === 'error') {
|
|
54
|
-
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: error.name, message: error.message }
|
|
54
|
+
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: error.name, message: error.message }), (0, jsx_runtime_1.jsx)("div", { style: errorWhileErrorStyle, children: "Error while getting stack trace:" }), (0, jsx_runtime_1.jsx)("div", { style: errorWhileErrorStyle, children: state.err.stack }), (0, jsx_runtime_1.jsx)("div", { style: errorWhileErrorStyle, children: "Report this in the Remotion repo." })] }));
|
|
55
55
|
}
|
|
56
56
|
if (state.type === 'no-record') {
|
|
57
|
-
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: error.name, message: error.message }
|
|
57
|
+
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)(ErrorTitle_1.ErrorTitle, { symbolicating: false, name: error.name, message: error.message }), (0, jsx_runtime_1.jsx)("div", { style: errorWhileErrorStyle, children: "Check the Terminal and browser console for error messages." })] }));
|
|
58
58
|
}
|
|
59
|
-
return ((0, jsx_runtime_1.jsx)("div", { style: container, children: (0, jsx_runtime_1.jsx)(ErrorDisplay_1.ErrorDisplay, { display: state.record }
|
|
59
|
+
return ((0, jsx_runtime_1.jsx)("div", { style: container, children: (0, jsx_runtime_1.jsx)(ErrorDisplay_1.ErrorDisplay, { display: state.record }) }));
|
|
60
60
|
};
|
|
61
61
|
exports.ErrorLoader = ErrorLoader;
|
|
@@ -36,6 +36,6 @@ const spacer = {
|
|
|
36
36
|
width: 5,
|
|
37
37
|
};
|
|
38
38
|
const ErrorTitle = ({ name, message, symbolicating }) => {
|
|
39
|
-
return ((0, jsx_runtime_1.jsxs)("div", { style: title, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("span", { style: errName, children: name }
|
|
39
|
+
return ((0, jsx_runtime_1.jsxs)("div", { style: title, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("span", { style: errName, children: name }), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("div", { style: row, children: [symbolicating ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Symbolicating_1.Symbolicating, {}), (0, jsx_runtime_1.jsx)("div", { style: spacer })] })) : null, (0, jsx_runtime_1.jsx)("div", { children: message })] })] }), (0, react_overlay_1.didUnmountReactApp)() ? null : (0, jsx_runtime_1.jsx)(DismissButton_1.DismissButton, {})] }));
|
|
40
40
|
};
|
|
41
41
|
exports.ErrorTitle = ErrorTitle;
|
|
@@ -85,6 +85,6 @@ const OpenInEditor = ({ stack }) => {
|
|
|
85
85
|
throw new Error('invalid state');
|
|
86
86
|
}
|
|
87
87
|
}, [state.type]);
|
|
88
|
-
return ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, disabled: state.type !== 'idle', children: label }
|
|
88
|
+
return ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, disabled: state.type !== 'idle', children: label }));
|
|
89
89
|
};
|
|
90
90
|
exports.OpenInEditor = OpenInEditor;
|
|
@@ -8,6 +8,6 @@ const SearchGithubIssues = ({ message }) => {
|
|
|
8
8
|
const openInBrowser = (0, react_1.useCallback)(() => {
|
|
9
9
|
window.open(`https://github.com/remotion-dev/remotion/issues?q=${encodeURIComponent(message)}`, '_blank');
|
|
10
10
|
}, [message]);
|
|
11
|
-
return (0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, children: "Search GitHub Issues" }
|
|
11
|
+
return (0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, children: "Search GitHub Issues" });
|
|
12
12
|
};
|
|
13
13
|
exports.SearchGithubIssues = SearchGithubIssues;
|
|
@@ -41,8 +41,8 @@ const StackElement = ({ s, lineNumberWidth, isFirst, defaultFunctionName }) => {
|
|
|
41
41
|
const toggleCodeFrame = (0, react_1.useCallback)(() => {
|
|
42
42
|
setShowCodeFrame((f) => !f);
|
|
43
43
|
}, []);
|
|
44
|
-
return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: header, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("div", { style: fnName, children: (_a = s.originalFunctionName) !== null && _a !== void 0 ? _a : defaultFunctionName }
|
|
44
|
+
return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: header, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("div", { style: fnName, children: (_a = s.originalFunctionName) !== null && _a !== void 0 ? _a : defaultFunctionName }), s.originalFileName ? ((0, jsx_runtime_1.jsxs)("div", { style: location, children: [(0, format_location_1.formatLocation)(s.originalFileName), ":", s.originalLineNumber] })) : null] }), s.originalScriptCode && s.originalScriptCode.length > 0 ? ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: toggleCodeFrame, children: showCodeFrame ? (0, jsx_runtime_1.jsx)(carets_1.CaretDown, {}) : (0, jsx_runtime_1.jsx)(carets_1.CaretRight, {}) })) : null] }), (0, jsx_runtime_1.jsx)("div", { children: s.originalScriptCode &&
|
|
45
45
|
s.originalScriptCode.length > 0 &&
|
|
46
|
-
showCodeFrame ? ((0, jsx_runtime_1.jsx)(CodeFrame_1.CodeFrame, { lineNumberWidth: lineNumberWidth, source: s.originalScriptCode }
|
|
46
|
+
showCodeFrame ? ((0, jsx_runtime_1.jsx)(CodeFrame_1.CodeFrame, { lineNumberWidth: lineNumberWidth, source: s.originalScriptCode })) : null })] }));
|
|
47
47
|
};
|
|
48
48
|
exports.StackElement = StackElement;
|
|
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.Symbolicating = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const Symbolicating = (props) => {
|
|
6
|
-
return ((0, jsx_runtime_1.jsxs)("svg", { id: "loading", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 32 32", width: "16", height: "16", fill: "white", ...props, children: [(0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(0 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0" }
|
|
6
|
+
return ((0, jsx_runtime_1.jsxs)("svg", { id: "loading", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 32 32", width: "16", height: "16", fill: "white", ...props, children: [(0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(0 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(45 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.125s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(90 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.25s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(135 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.375s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(180 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.5s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(225 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.675s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(270 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.75s" }) }), (0, jsx_runtime_1.jsx)("path", { opacity: ".1", d: "M14 0 H18 V8 H14 z", transform: "rotate(315 16 16)", children: (0, jsx_runtime_1.jsx)("animate", { attributeName: "opacity", from: "1", to: ".1", dur: "1s", repeatCount: "indefinite", begin: "0.875s" }) })] }));
|
|
7
7
|
};
|
|
8
8
|
exports.Symbolicating = Symbolicating;
|
|
@@ -3,10 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.CaretDown = exports.CaretRight = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const CaretRight = () => {
|
|
6
|
-
return ((0, jsx_runtime_1.jsx)("svg", { style: { height: 20 }, "aria-hidden": "true", focusable: "false", role: "img", viewBox: "0 0 192 512", children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M0 384.662V127.338c0-17.818 21.543-26.741 34.142-14.142l128.662 128.662c7.81 7.81 7.81 20.474 0 28.284L34.142 398.804C21.543 411.404 0 402.48 0 384.662z" }
|
|
6
|
+
return ((0, jsx_runtime_1.jsx)("svg", { style: { height: 20 }, "aria-hidden": "true", focusable: "false", role: "img", viewBox: "0 0 192 512", children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M0 384.662V127.338c0-17.818 21.543-26.741 34.142-14.142l128.662 128.662c7.81 7.81 7.81 20.474 0 28.284L34.142 398.804C21.543 411.404 0 402.48 0 384.662z" }) }));
|
|
7
7
|
};
|
|
8
8
|
exports.CaretRight = CaretRight;
|
|
9
9
|
const CaretDown = () => {
|
|
10
|
-
return ((0, jsx_runtime_1.jsx)("svg", { "aria-hidden": "true", focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", style: { height: 20 }, children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z" }
|
|
10
|
+
return ((0, jsx_runtime_1.jsx)("svg", { "aria-hidden": "true", focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", style: { height: 20 }, children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z" }) }));
|
|
11
11
|
};
|
|
12
12
|
exports.CaretDown = CaretDown;
|
|
@@ -9,10 +9,10 @@ const client_1 = __importDefault(require("react-dom/client"));
|
|
|
9
9
|
const Overlay_1 = require("./Overlay");
|
|
10
10
|
const mountRemotionOverlay = () => {
|
|
11
11
|
if (client_1.default.createRoot) {
|
|
12
|
-
client_1.default.createRoot(document.getElementById('remotion-error-overlay')).render((0, jsx_runtime_1.jsx)(Overlay_1.Overlay, {}
|
|
12
|
+
client_1.default.createRoot(document.getElementById('remotion-error-overlay')).render((0, jsx_runtime_1.jsx)(Overlay_1.Overlay, {}));
|
|
13
13
|
}
|
|
14
14
|
else {
|
|
15
|
-
client_1.default.render((0, jsx_runtime_1.jsx)(Overlay_1.Overlay, {}
|
|
15
|
+
client_1.default.render((0, jsx_runtime_1.jsx)(Overlay_1.Overlay, {}), document.getElementById('remotion-error-overlay'));
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
18
|
exports.mountRemotionOverlay = mountRemotionOverlay;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import webpack from 'webpack';
|
|
2
|
-
import { LoaderOptions } from './interfaces';
|
|
1
|
+
import type webpack from 'webpack';
|
|
2
|
+
import type { LoaderOptions } from './interfaces';
|
|
3
3
|
declare function ESBuildLoader(this: webpack.LoaderContext<LoaderOptions>, source: string): Promise<void>;
|
|
4
4
|
export default ESBuildLoader;
|
|
@@ -35,6 +35,7 @@ async function ESBuildLoader(source) {
|
|
|
35
35
|
sourcefile: this.resourcePath,
|
|
36
36
|
};
|
|
37
37
|
if (!('tsconfigRaw' in transformOptions) && isTypescriptInstalled()) {
|
|
38
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-imports
|
|
38
39
|
const typescript = require('typescript');
|
|
39
40
|
const tsConfig = typescript.readConfigFile(tsConfigPath, typescript.sys.readFile);
|
|
40
41
|
transformOptions.tsconfigRaw = tsConfig.config;
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
25
25
|
* SOFTWARE.
|
|
26
26
|
*/
|
|
27
|
-
import webpack from 'webpack';
|
|
27
|
+
import type webpack from 'webpack';
|
|
28
28
|
export declare class ReactFreshWebpackPlugin {
|
|
29
29
|
apply(compiler: webpack.Compiler): void;
|
|
30
30
|
}
|
|
@@ -4,33 +4,6 @@
|
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ReactFreshWebpackPlugin = void 0;
|
|
7
|
-
/**
|
|
8
|
-
* The MIT License (MIT)
|
|
9
|
-
*
|
|
10
|
-
* Copyright (c) 2020 Vercel, Inc.
|
|
11
|
-
*
|
|
12
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
13
|
-
* of this software and associated documentation files (the "Software"), to deal
|
|
14
|
-
* in the Software without restriction, including without limitation the rights
|
|
15
|
-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16
|
-
* copies of the Software, and to permit persons to whom the Software is
|
|
17
|
-
* furnished to do so, subject to the following conditions:
|
|
18
|
-
*
|
|
19
|
-
* The above copyright notice and this permission notice shall be included in all
|
|
20
|
-
* copies or substantial portions of the Software.
|
|
21
|
-
*
|
|
22
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
23
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
24
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
25
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
26
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
27
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
28
|
-
* SOFTWARE.
|
|
29
|
-
*/
|
|
30
|
-
// This file is copied from the @vercel/next.js, with removed TS annotations
|
|
31
|
-
// minor tweaks, and removed all webpack v4-related functionality
|
|
32
|
-
//
|
|
33
|
-
// https://github.com/vercel/next.js/blob/canary/packages/react-refresh-utils/ReactRefreshWebpackPlugin.ts
|
|
34
7
|
const webpack_1 = require("webpack");
|
|
35
8
|
class ReactRefreshRuntimeModule extends webpack_1.RuntimeModule {
|
|
36
9
|
constructor() {
|
|
@@ -30,6 +30,6 @@
|
|
|
30
30
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
31
31
|
* SOFTWARE.
|
|
32
32
|
*/
|
|
33
|
-
import { LoaderDefinition } from 'webpack';
|
|
33
|
+
import type { LoaderDefinition } from 'webpack';
|
|
34
34
|
declare const ReactRefreshLoader: LoaderDefinition;
|
|
35
35
|
export default ReactRefreshLoader;
|
package/dist/get-port.js
CHANGED
|
@@ -5,16 +5,26 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getDesiredPort = void 0;
|
|
7
7
|
const net_1 = __importDefault(require("net"));
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
});
|
|
8
|
+
const p_limit_1 = require("./p-limit");
|
|
9
|
+
const getAvailablePort = (portToTry) => new Promise((resolve) => {
|
|
10
|
+
let status = 'unavailable';
|
|
11
|
+
const host = '127.0.0.1';
|
|
12
|
+
const socket = new net_1.default.Socket();
|
|
13
|
+
socket.on('connect', () => {
|
|
14
|
+
status = 'unavailable';
|
|
15
|
+
socket.destroy();
|
|
17
16
|
});
|
|
17
|
+
socket.setTimeout(1000);
|
|
18
|
+
socket.on('timeout', () => {
|
|
19
|
+
status = 'unavailable';
|
|
20
|
+
socket.destroy();
|
|
21
|
+
resolve(status);
|
|
22
|
+
});
|
|
23
|
+
socket.on('error', () => {
|
|
24
|
+
status = 'available';
|
|
25
|
+
});
|
|
26
|
+
socket.on('close', () => resolve(status));
|
|
27
|
+
socket.connect(portToTry, host);
|
|
18
28
|
});
|
|
19
29
|
const portCheckSequence = function* (ports) {
|
|
20
30
|
if (ports) {
|
|
@@ -22,30 +32,18 @@ const portCheckSequence = function* (ports) {
|
|
|
22
32
|
}
|
|
23
33
|
yield 0; // Fall back to 0 if anything else failed
|
|
24
34
|
};
|
|
25
|
-
const isPortAvailable = async (port) => {
|
|
26
|
-
try {
|
|
27
|
-
await getAvailablePort(port);
|
|
28
|
-
return true;
|
|
29
|
-
}
|
|
30
|
-
catch (error) {
|
|
31
|
-
if (!['EADDRINUSE', 'EACCES'].includes(error.code)) {
|
|
32
|
-
throw error;
|
|
33
|
-
}
|
|
34
|
-
return false;
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
35
|
const getPort = async (from, to) => {
|
|
38
36
|
const ports = makeRange(from, to);
|
|
39
37
|
for (const port of portCheckSequence(ports)) {
|
|
40
|
-
if (await
|
|
38
|
+
if ((await getAvailablePort(port)) === 'available') {
|
|
41
39
|
return port;
|
|
42
40
|
}
|
|
43
41
|
}
|
|
44
42
|
throw new Error('No available ports found');
|
|
45
43
|
};
|
|
46
|
-
const
|
|
44
|
+
const getDesiredPortUnlimited = async (desiredPort, from, to) => {
|
|
47
45
|
if (typeof desiredPort !== 'undefined' &&
|
|
48
|
-
(await
|
|
46
|
+
(await getAvailablePort(desiredPort)) === 'available') {
|
|
49
47
|
return desiredPort;
|
|
50
48
|
}
|
|
51
49
|
const actualPort = await getPort(from, to);
|
|
@@ -55,6 +53,10 @@ const getDesiredPort = async (desiredPort, from, to) => {
|
|
|
55
53
|
}
|
|
56
54
|
return actualPort;
|
|
57
55
|
};
|
|
56
|
+
const limit = (0, p_limit_1.pLimit)(1);
|
|
57
|
+
const getDesiredPort = (desiredPort, from, to) => {
|
|
58
|
+
return limit(getDesiredPortUnlimited, desiredPort, from, to);
|
|
59
|
+
};
|
|
58
60
|
exports.getDesiredPort = getDesiredPort;
|
|
59
61
|
const makeRange = (from, to) => {
|
|
60
62
|
if (!Number.isInteger(from) || !Number.isInteger(to)) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Homepage =
|
|
3
|
+
exports.Homepage = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
6
|
const bundle_mode_1 = require("../bundle-mode");
|
|
@@ -47,17 +47,16 @@ const AvailableCompositions = () => {
|
|
|
47
47
|
(0, renderEntry_1.setBundleModeAndUpdate)({ type: 'evaluation' });
|
|
48
48
|
}, []);
|
|
49
49
|
if ((0, bundle_mode_1.getBundleMode)().type !== 'evaluation') {
|
|
50
|
-
return ((0, jsx_runtime_1.jsx)("button", { type: "button", onClick: showComps, children: "Click here to see a list of available compositions." }
|
|
50
|
+
return ((0, jsx_runtime_1.jsx)("button", { type: "button", onClick: showComps, children: "Click here to see a list of available compositions." }));
|
|
51
51
|
}
|
|
52
|
-
return ((0, jsx_runtime_1.jsxs)("div", { children: [comps === null ? (0, jsx_runtime_1.jsx)("p", { children: "Loading compositions..." }
|
|
52
|
+
return ((0, jsx_runtime_1.jsxs)("div", { children: [comps === null ? (0, jsx_runtime_1.jsx)("p", { children: "Loading compositions..." }) : null, (0, jsx_runtime_1.jsx)("ul", { children: comps === null
|
|
53
53
|
? null
|
|
54
54
|
: comps.map((c) => {
|
|
55
55
|
return (0, jsx_runtime_1.jsx)("li", { children: c.id }, c.id);
|
|
56
|
-
}) }
|
|
56
|
+
}) })] }));
|
|
57
57
|
};
|
|
58
|
-
exports.AvailableCompositions = AvailableCompositions;
|
|
59
58
|
const Homepage = () => {
|
|
60
59
|
const url = window.location.origin + window.location.pathname;
|
|
61
|
-
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)("h1", { children: "Remotion Bundle" }
|
|
60
|
+
return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)("h1", { children: "Remotion Bundle" }), "This is a website which contains a bundled Remotion video. You can render videos based on this URL.", (0, jsx_runtime_1.jsx)("h2", { children: "Available compositions" }), (0, jsx_runtime_1.jsx)(AvailableCompositions, {}), (0, jsx_runtime_1.jsx)("h2", { children: "How to render" }), "Locally: ", (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("div", { style: pre, children: ["npx remotion render ", url, " ", '<comp-name> <output-location>'] }), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsx)("br", {}), "With Remotion Lambda: ", (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("div", { style: pre, children: ["npx remotion lambda render ", url, " ", '<comp-name>'] }), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("p", { children: ["You can also render still images, and use the Node.JS APIs", ' ', (0, jsx_runtime_1.jsx)("code", { children: "getCompositions()" }), ", ", (0, jsx_runtime_1.jsx)("code", { children: "renderMedia()" }), ",", ' ', (0, jsx_runtime_1.jsx)("code", { children: "renderMediaOnLambda()" }), ", ", (0, jsx_runtime_1.jsx)("code", { children: "renderStill()" }), " and", ' ', (0, jsx_runtime_1.jsx)("code", { children: "renderStillOnLambda()" }), " with this URL."] }), (0, jsx_runtime_1.jsxs)("p", { children: ["Visit", ' ', (0, jsx_runtime_1.jsx)("a", { href: "https://remotion.dev/docs", target: "_blank", children: "remotion.dev/docs" }), ' ', "to read the documentation."] })] }));
|
|
62
61
|
};
|
|
63
62
|
exports.Homepage = Homepage;
|
|
@@ -50,7 +50,7 @@ const processUpdate = function (hash, moduleMap, options) {
|
|
|
50
50
|
async function check() {
|
|
51
51
|
var _a;
|
|
52
52
|
const cb = function (err, updatedModules) {
|
|
53
|
-
var _a
|
|
53
|
+
var _a;
|
|
54
54
|
if (err)
|
|
55
55
|
return handleError(err);
|
|
56
56
|
if (!updatedModules) {
|
|
@@ -69,7 +69,7 @@ const processUpdate = function (hash, moduleMap, options) {
|
|
|
69
69
|
logUpdates(updatedModules, renewedModules);
|
|
70
70
|
};
|
|
71
71
|
const applyResult = (_a = module.hot) === null || _a === void 0 ? void 0 : _a.apply(applyOptions, applyCallback);
|
|
72
|
-
if (
|
|
72
|
+
if (applyResult === null || applyResult === void 0 ? void 0 : applyResult.then) {
|
|
73
73
|
// HotModuleReplacement.runtime.js refers to the result as `outdatedModules`
|
|
74
74
|
applyResult
|
|
75
75
|
.then((outdatedModules) => {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const indexHtml: (staticHash: string, baseDir: string, editorName: string | null, inputProps: object | null) => string;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.indexHtml = void 0;
|
|
7
|
+
const path_1 = __importDefault(require("path"));
|
|
8
|
+
const indexHtml = (staticHash, baseDir, editorName, inputProps) => `
|
|
9
|
+
<!DOCTYPE html>
|
|
10
|
+
<html lang="en">
|
|
11
|
+
<head>
|
|
12
|
+
<meta charset="UTF-8" />
|
|
13
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
14
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" />
|
|
15
|
+
<link rel="icon" type="image/png" href="/remotion.png" />
|
|
16
|
+
<title>Remotion Preview</title>
|
|
17
|
+
</head>
|
|
18
|
+
<body>
|
|
19
|
+
<script>window.remotion_staticBase = "${staticHash}";</script>
|
|
20
|
+
<div id="video-container"></div>
|
|
21
|
+
<div id="explainer-container"></div>
|
|
22
|
+
${editorName
|
|
23
|
+
? `<script>window.remotion_editorName = "${editorName}";</script>`
|
|
24
|
+
: '<script>window.remotion_editorName = null;</script>'}
|
|
25
|
+
<script>window.remotion_projectName = ${JSON.stringify(path_1.default.basename(process.cwd()))};</script>
|
|
26
|
+
<script>window.remotion_cwd = ${JSON.stringify(process.cwd())};</script>
|
|
27
|
+
${inputProps
|
|
28
|
+
? ` <script>window.remotion_inputProps = ${JSON.stringify(JSON.stringify(inputProps))};</script>
|
|
29
|
+
`
|
|
30
|
+
: ''}
|
|
31
|
+
|
|
32
|
+
<div id="container"></div>
|
|
33
|
+
<div id="menuportal-0"></div>
|
|
34
|
+
<div id="menuportal-1"></div>
|
|
35
|
+
<div id="menuportal-2"></div>
|
|
36
|
+
<div id="menuportal-3"></div>
|
|
37
|
+
<div id="menuportal-4"></div>
|
|
38
|
+
<div id="menuportal-5"></div>
|
|
39
|
+
<div id="remotion-error-overlay"></div>
|
|
40
|
+
<script src="${baseDir}bundle.js"></script>
|
|
41
|
+
</body>
|
|
42
|
+
</html>
|
|
43
|
+
`.trim();
|
|
44
|
+
exports.indexHtml = indexHtml;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import esbuild = require('esbuild');
|
|
2
|
+
import webpack = require('webpack');
|
|
2
3
|
export declare const BundlerInternals: {
|
|
3
|
-
startServer: (entry: string, userDefinedComponent: string, options?: {
|
|
4
|
-
webpackOverride?: import("remotion").WebpackOverrideFn | undefined;
|
|
5
|
-
inputProps?: object | undefined;
|
|
6
|
-
envVariables?: Record<string, string> | undefined;
|
|
7
|
-
port?: number | undefined;
|
|
8
|
-
maxTimelineTracks?: number | undefined;
|
|
9
|
-
} | undefined) => Promise<number>;
|
|
10
|
-
cacheExists: (environment: "development" | "production", inputProps: object | null) => boolean;
|
|
11
|
-
clearCache: (environment: "development" | "production", inputProps: object | null) => Promise<void>;
|
|
12
|
-
getLatestRemotionVersion: () => Promise<any>;
|
|
13
|
-
getPackageManager: () => import("./get-package-manager").PackageManager | "unknown";
|
|
14
|
-
lockFilePaths: {
|
|
15
|
-
manager: import("./get-package-manager").PackageManager;
|
|
16
|
-
path: string;
|
|
17
|
-
}[];
|
|
18
4
|
esbuild: typeof esbuild;
|
|
5
|
+
webpackConfig: ({ entry, userDefinedComponent, outDir, environment, webpackOverride, onProgressUpdate, enableCaching, envVariables, maxTimelineTracks, entryPoints, }: {
|
|
6
|
+
entry: string;
|
|
7
|
+
userDefinedComponent: string;
|
|
8
|
+
outDir: string;
|
|
9
|
+
environment: "development" | "production";
|
|
10
|
+
webpackOverride: import("remotion").WebpackOverrideFn;
|
|
11
|
+
onProgressUpdate?: ((f: number) => void) | undefined;
|
|
12
|
+
enableCaching?: boolean | undefined;
|
|
13
|
+
envVariables: Record<string, string>;
|
|
14
|
+
maxTimelineTracks: number;
|
|
15
|
+
entryPoints: string[];
|
|
16
|
+
}) => webpack.Configuration;
|
|
17
|
+
indexHtml: (staticHash: string, baseDir: string, editorName: string | null, inputProps: object | null) => string;
|
|
18
|
+
cacheExists: (environment: "development" | "production") => boolean;
|
|
19
|
+
clearCache: (environment: "development" | "production") => Promise<void>;
|
|
19
20
|
};
|
|
20
21
|
export { bundle } from './bundle';
|
|
21
|
-
export {
|
|
22
|
-
export type { ProjectInfo } from './project-info';
|
|
22
|
+
export { webpack };
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.bundle = exports.BundlerInternals = void 0;
|
|
4
|
-
const
|
|
5
|
-
const get_package_manager_1 = require("./get-package-manager");
|
|
6
|
-
const start_server_1 = require("./start-server");
|
|
3
|
+
exports.webpack = exports.bundle = exports.BundlerInternals = void 0;
|
|
4
|
+
const index_html_1 = require("./index-html");
|
|
7
5
|
const webpack_cache_1 = require("./webpack-cache");
|
|
6
|
+
const webpack_config_1 = require("./webpack-config");
|
|
8
7
|
const esbuild = require("esbuild");
|
|
8
|
+
const webpack = require("webpack");
|
|
9
|
+
exports.webpack = webpack;
|
|
9
10
|
exports.BundlerInternals = {
|
|
10
|
-
|
|
11
|
+
esbuild,
|
|
12
|
+
webpackConfig: webpack_config_1.webpackConfig,
|
|
13
|
+
indexHtml: index_html_1.indexHtml,
|
|
11
14
|
cacheExists: webpack_cache_1.cacheExists,
|
|
12
15
|
clearCache: webpack_cache_1.clearCache,
|
|
13
|
-
getLatestRemotionVersion: get_latest_remotion_version_1.getLatestRemotionVersion,
|
|
14
|
-
getPackageManager: get_package_manager_1.getPackageManager,
|
|
15
|
-
lockFilePaths: get_package_manager_1.lockFilePaths,
|
|
16
|
-
esbuild,
|
|
17
16
|
};
|
|
18
17
|
var bundle_1 = require("./bundle");
|
|
19
18
|
Object.defineProperty(exports, "bundle", { enumerable: true, get: function () { return bundle_1.bundle; } });
|