feat: add initial OG data and improve genrator system

This commit is contained in:
Morten Olsen
2022-04-03 12:18:25 +02:00
parent e6e938bd42
commit 56235d8f5e
15 changed files with 412 additions and 37 deletions

View File

@@ -14,18 +14,9 @@ const withLatex = (nextConfig = {}) => {
use: [{
loader: require.resolve('./webpack.js'),
options: {
publicPath: `${nextConfig.assetPrefix || nextConfig.basePath || ''}/_next/static/images/`,
outputPath: `${outputPath}static/images/`,
name: (name) => {
const fileName = path.basename(name);
const parts = fileName.split('.');
parts.pop();
const ext = parts.pop();
return `${parts.join('.')}.[hash].${ext}`;
},
esModule: nextConfig.esModule || false,
isDev: dev,
publicPath: `${nextConfig.assetPrefix || nextConfig.basePath || ''}/_next/static/assets/`,
outputPath: `${outputPath}static/assets/`,
},
}],
});