2020-01-04 19:37:44 +00:00
|
|
|
const autoprefixer = require('autoprefixer');
|
|
|
|
const tailwindcss = require('tailwindcss');
|
|
|
|
const postcssPurgecss = require(`@fullhuman/postcss-purgecss`);
|
|
|
|
|
|
|
|
const purgecss = postcssPurgecss({
|
|
|
|
// Specify the paths to all of the template files in your project.
|
|
|
|
content: [
|
|
|
|
'./public/**/*.html',
|
|
|
|
'./src/**/*.vue',
|
|
|
|
],
|
|
|
|
// Include any special characters you're using in this regular expression.
|
|
|
|
// See: https://tailwindcss.com/docs/controlling-file-size/#understanding-the-regex
|
|
|
|
defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [],
|
|
|
|
// Whitelist auto generated classes for transitions and router links.
|
|
|
|
// From: https://github.com/ky-is/vue-cli-plugin-tailwind
|
|
|
|
whitelistPatterns: [/-(leave|enter|appear)(|-(to|from|active))$/, /^(?!(|.*?:)cursor-move).+-move$/, /^router-link(|-exact)-active$/],
|
|
|
|
});
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
title: "Yuika documentation",
|
|
|
|
description: "",
|
|
|
|
themeConfig: {
|
2020-01-05 18:46:32 +00:00
|
|
|
sidebar: 'auto',
|
2020-01-04 19:37:44 +00:00
|
|
|
},
|
|
|
|
postcss: {
|
|
|
|
plugins: [
|
|
|
|
require("autoprefixer"),
|
|
|
|
require("tailwindcss")("./tailwind.config.js"),
|
|
|
|
...process.env.NODE_ENV === 'production'
|
|
|
|
? [purgecss]
|
|
|
|
: [],
|
|
|
|
]
|
|
|
|
}
|
|
|
|
};
|