@remotion/bundler 3.3.10 → 3.3.11
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.js +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/webpack-config.d.ts +2 -1
- package/dist/webpack-config.js +4 -5
- package/package.json +3 -3
- package/dist/get-etag.d.ts +0 -1
- package/dist/get-etag.js +0 -24
- package/dist/read-recursively.d.ts +0 -6
- package/dist/read-recursively.js +0 -64
package/dist/bundle.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import esbuild = require('esbuild');
|
|
|
2
2
|
import webpack = require('webpack');
|
|
3
3
|
export declare const BundlerInternals: {
|
|
4
4
|
esbuild: typeof esbuild;
|
|
5
|
-
webpackConfig: ({ entry, userDefinedComponent, outDir, environment, webpackOverride, onProgress, enableCaching, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, }: {
|
|
5
|
+
webpackConfig: ({ entry, userDefinedComponent, outDir, environment, webpackOverride, onProgress, enableCaching, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, poll, }: {
|
|
6
6
|
entry: string;
|
|
7
7
|
userDefinedComponent: string;
|
|
8
8
|
outDir: string;
|
|
@@ -15,6 +15,7 @@ export declare const BundlerInternals: {
|
|
|
15
15
|
keyboardShortcutsEnabled: boolean;
|
|
16
16
|
entryPoints: string[];
|
|
17
17
|
remotionRoot: string;
|
|
18
|
+
poll: number | null;
|
|
18
19
|
}) => [string, webpack.Configuration];
|
|
19
20
|
indexHtml: ({ baseDir, editorName, inputProps, envVariables, staticHash, remotionRoot, previewServerCommand, numberOfAudioTags, includeFavicon, title, }: {
|
|
20
21
|
staticHash: string;
|
package/dist/webpack-config.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { WebpackConfiguration, WebpackOverrideFn } from 'remotion';
|
|
2
|
-
export declare const webpackConfig: ({ entry, userDefinedComponent, outDir, environment, webpackOverride, onProgress, enableCaching, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, }: {
|
|
2
|
+
export declare const webpackConfig: ({ entry, userDefinedComponent, outDir, environment, webpackOverride, onProgress, enableCaching, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, poll, }: {
|
|
3
3
|
entry: string;
|
|
4
4
|
userDefinedComponent: string;
|
|
5
5
|
outDir: string;
|
|
@@ -12,4 +12,5 @@ export declare const webpackConfig: ({ entry, userDefinedComponent, outDir, envi
|
|
|
12
12
|
keyboardShortcutsEnabled: boolean;
|
|
13
13
|
entryPoints: string[];
|
|
14
14
|
remotionRoot: string;
|
|
15
|
+
poll: number | null;
|
|
15
16
|
}) => [string, WebpackConfiguration];
|
package/dist/webpack-config.js
CHANGED
|
@@ -51,7 +51,7 @@ const esbuildLoaderOptions = {
|
|
|
51
51
|
function truthy(value) {
|
|
52
52
|
return Boolean(value);
|
|
53
53
|
}
|
|
54
|
-
const webpackConfig = ({ entry, userDefinedComponent, outDir, environment, webpackOverride = (f) => f, onProgress, enableCaching = true, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, }) => {
|
|
54
|
+
const webpackConfig = ({ entry, userDefinedComponent, outDir, environment, webpackOverride = (f) => f, onProgress, enableCaching = true, envVariables, maxTimelineTracks, entryPoints, remotionRoot, keyboardShortcutsEnabled, poll, }) => {
|
|
55
55
|
const conf = webpackOverride({
|
|
56
56
|
optimization: {
|
|
57
57
|
minimize: false,
|
|
@@ -64,12 +64,11 @@ const webpackConfig = ({ entry, userDefinedComponent, outDir, environment, webpa
|
|
|
64
64
|
},
|
|
65
65
|
},
|
|
66
66
|
watchOptions: {
|
|
67
|
+
poll: poll !== null && poll !== void 0 ? poll : undefined,
|
|
67
68
|
aggregateTimeout: 0,
|
|
68
69
|
ignored: ['**/.git/**', '**/node_modules/**'],
|
|
69
70
|
},
|
|
70
|
-
devtool:
|
|
71
|
-
? 'cheap-module-source-map'
|
|
72
|
-
: 'cheap-module-source-map',
|
|
71
|
+
devtool: 'cheap-module-source-map',
|
|
73
72
|
entry: [
|
|
74
73
|
// Fast Refresh must come first,
|
|
75
74
|
// because setup-environment imports ReactDOM.
|
|
@@ -109,7 +108,7 @@ const webpackConfig = ({ entry, userDefinedComponent, outDir, environment, webpa
|
|
|
109
108
|
assetModuleFilename: environment === 'development' ? '[path][name][ext]' : '[hash][ext]',
|
|
110
109
|
},
|
|
111
110
|
resolve: {
|
|
112
|
-
extensions: ['.ts', '.tsx', '.js', '.jsx'],
|
|
111
|
+
extensions: ['.ts', '.tsx', '.web.js', '.js', '.jsx'],
|
|
113
112
|
alias: {
|
|
114
113
|
// Only one version of react
|
|
115
114
|
'react/jsx-runtime': require.resolve('react/jsx-runtime'),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/bundler",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.11",
|
|
4
4
|
"description": "Bundler for Remotion",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"css-loader": "5.2.7",
|
|
27
27
|
"esbuild": "0.15.13",
|
|
28
28
|
"react-refresh": "0.9.0",
|
|
29
|
-
"remotion": "3.3.
|
|
29
|
+
"remotion": "3.3.11",
|
|
30
30
|
"style-loader": "2.0.0",
|
|
31
31
|
"webpack": "5.74.0"
|
|
32
32
|
},
|
|
@@ -64,5 +64,5 @@
|
|
|
64
64
|
"publishConfig": {
|
|
65
65
|
"access": "public"
|
|
66
66
|
},
|
|
67
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "08404196c439c2bf1f06bbb7a99a6fd84d5158e1"
|
|
68
68
|
}
|
package/dist/get-etag.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const getEtagOfFile: (filePath: string) => Promise<string>;
|
package/dist/get-etag.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
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.getEtagOfFile = void 0;
|
|
7
|
-
const fs_1 = __importDefault(require("fs"));
|
|
8
|
-
const crypto_1 = __importDefault(require("crypto"));
|
|
9
|
-
const chunk = 1024 * 1024 * 5; // 5MB
|
|
10
|
-
const md5 = (data) => crypto_1.default.createHash('md5').update(data).digest('hex');
|
|
11
|
-
const getEtagOfFile = async (filePath) => {
|
|
12
|
-
const stream = await fs_1.default.promises.readFile(filePath);
|
|
13
|
-
if (stream.length <= chunk) {
|
|
14
|
-
return md5(stream);
|
|
15
|
-
}
|
|
16
|
-
const md5Chunks = [];
|
|
17
|
-
const chunksNumber = Math.ceil(stream.length / chunk);
|
|
18
|
-
for (let i = 0; i < chunksNumber; i++) {
|
|
19
|
-
const chunkStream = stream.slice(i * chunk, (i + 1) * chunk);
|
|
20
|
-
md5Chunks.push(md5(chunkStream));
|
|
21
|
-
}
|
|
22
|
-
return `${md5(Buffer.from(md5Chunks.join(''), 'hex'))}-${chunksNumber}`;
|
|
23
|
-
};
|
|
24
|
-
exports.getEtagOfFile = getEtagOfFile;
|
package/dist/read-recursively.js
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
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);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
-
};
|
|
28
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.readRecursively = void 0;
|
|
30
|
-
const fs_1 = __importStar(require("fs"));
|
|
31
|
-
const path_1 = __importDefault(require("path"));
|
|
32
|
-
const readRecursively = ({ folder, output = [], startPath, }) => {
|
|
33
|
-
const absFolder = path_1.default.join(startPath, folder);
|
|
34
|
-
const files = fs_1.default.readdirSync(absFolder);
|
|
35
|
-
for (const file of files) {
|
|
36
|
-
if (file.startsWith('.DS_Store')) {
|
|
37
|
-
continue;
|
|
38
|
-
}
|
|
39
|
-
const stat = (0, fs_1.statSync)(path_1.default.join(absFolder, file));
|
|
40
|
-
if (stat.isDirectory()) {
|
|
41
|
-
(0, exports.readRecursively)({ startPath, folder: path_1.default.join(folder, file), output });
|
|
42
|
-
}
|
|
43
|
-
else if (stat.isFile()) {
|
|
44
|
-
output.push({
|
|
45
|
-
path: path_1.default.join(folder, file),
|
|
46
|
-
lastModified: Math.floor(stat.mtimeMs),
|
|
47
|
-
sizeInBytes: stat.size,
|
|
48
|
-
});
|
|
49
|
-
}
|
|
50
|
-
else if (stat.isSymbolicLink()) {
|
|
51
|
-
const realpath = fs_1.default.realpathSync(path_1.default.join(folder, file));
|
|
52
|
-
const realStat = fs_1.default.statSync(realpath);
|
|
53
|
-
if (realStat.isFile()) {
|
|
54
|
-
output.push({
|
|
55
|
-
path: realpath,
|
|
56
|
-
lastModified: Math.floor(realStat.mtimeMs),
|
|
57
|
-
sizeInBytes: realStat.size,
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
return output.sort((a, b) => a.path.localeCompare(b.path));
|
|
63
|
-
};
|
|
64
|
-
exports.readRecursively = readRecursively;
|