Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// Markdown
config.module.rules.push({
test: /\.md$/,
loader: path.resolve(__dirname, './webpack/markdown-loader.js'),
include: path.resolve(__dirname, './content'),
options: {
markdown
}
})
},
/*
** PostCSS
*/
postcss: {
plugins: postcss.plugins(tailwindJS)
},
babel: {
presets({ isServer }) {
return [
[
require.resolve('@nuxt/babel-preset-app'),
{
buildTarget: isServer ? 'server' : 'client',
corejs: { version: 3 }
}
]
]
}
}
},
const getLang = $page => $page._computed.$lang.split('-')[0]
const getGitLastUpdatedTimeStamp = (filePath) => {
try {
return parseInt(spawn.sync('git', ['log', '-1', '--format=%ct', filePath]).stdout.toString('utf-8')) * 1000
} catch (e) {
return new Date()
}
}
module.exports = {
title: 'Statusfy Documentation',
description: 'A marvelous open source Status Page system',
evergreen: true,
postcss: {
puglins: postcss.plugins()
},
extendMarkdown(md) {
md.use(require('markdown-it-imsize'));
md.use(require("markdown-it-block-image"), {
outputContainer: 'p',
containerClassName: 'img-container'
});
},
head: [
['link', { rel: 'manifest', href: '/manifest.json' }],
['link', { rel: 'icon', type: 'image/png', sizes: '16x16', href: '/assets/icons/favicon-16x16.png' }],
['link', { rel: 'icon', type: 'image/png', sizes: '32x32', href: '/assets/icons/favicon-32x32.png' }],
['link', { rel: 'icon', type: 'image/png', sizes: '96x96', href: '/assets/icons/favicon-96x96.png' }],
['link', { rel: 'icon', type: 'image/png', sizes: '192x192', href: '/assets/icons/android-icon-192x192.png' }],
['meta', { name: 'theme-color', content: '#3e4e88' }],
['meta', { name: 'apple-mobile-web-app-capable', content: 'yes' }],
analyze: true,
/*
** Router
*/
router: {
linkActiveClass: "active",
linkExactActiveClass: "exact",
scrollBehavior: (to, from, savedPosition) => {
return { x: 0, y: 0 };
}
},
/*
** PostCSS
*/
postcss: {
plugins: postcss.plugins(tailwindJS)
},
babel: {
presets({ isServer }) {
return [
[
require.resolve("@nuxt/babel-preset-app"),
{
buildTarget: isServer ? "server" : "client",
corejs: { version: 3 }
}
]
];
}
}
},
const { postcss, path } = require('@statusfy/common')
const tailwindJS = path.join(__dirname, 'tailwind.js')
module.exports = {
plugins: postcss.plugins(tailwindJS)
}
const { postcss, path } = require("@statusfy/common");
const tailwindJS = path.join(__dirname, "tailwind.js");
module.exports = {
plugins: postcss.plugins(tailwindJS)
};