Skip to content

Commit d0a4343

Browse files
committed
yarn add file-loader, update next.config
Enabled loading of .mp4 files
1 parent e42088b commit d0a4343

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed

next.config.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,15 @@ module.exports = (phase, { defaultConfig }) => {
2828
test: /\.svg$/,
2929
use: '@svgr/webpack',
3030
})
31+
config.module.rules.push({
32+
test: /\.mp4$/,
33+
use: {
34+
loader: 'file-loader',
35+
options: {
36+
name: '[name].[ext]',
37+
},
38+
},
39+
});
3140

3241
return config;
3342
},

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
"@emotion/react": "^11.11.1",
2323
"@emotion/styled": "^11.11.0",
2424
"clipboard": "^2.0.11",
25+
"file-loader": "^6.2.0",
2526
"focus-trap-react": "^10.2.3",
2627
"framer-motion": "^10.13.0",
2728
"gray-matter": "^4.0.3",

yarn.lock

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7841,6 +7841,14 @@ file-entry-cache@^6.0.1:
78417841
dependencies:
78427842
flat-cache "^3.0.4"
78437843

7844+
file-loader@^6.2.0:
7845+
version "6.2.0"
7846+
resolved "https://registry.yarnpkg.com/file-loader/-/file-loader-6.2.0.tgz#baef7cf8e1840df325e4390b4484879480eebe4d"
7847+
integrity sha512-qo3glqyTa61Ytg4u73GultjHGjdRyig3tG6lPtyX/jOEJvHif9uB0/OCI2Kif6ctF3caQTW2G5gym21oAsI4pw==
7848+
dependencies:
7849+
loader-utils "^2.0.0"
7850+
schema-utils "^3.0.0"
7851+
78447852
78457853
version "2.3.0"
78467854
resolved "https://registry.yarnpkg.com/file-system-cache/-/file-system-cache-2.3.0.tgz#201feaf4c8cd97b9d0d608e96861bb6005f46fe6"

0 commit comments

Comments
 (0)