build config updated

copying robots.txt moved to separate script
export script merged with build script
This commit is contained in:
tmshv committed 2019-10-13 18:35:01 +03:00
1 parent 0ae9601309
commit dded475c47
3 files changed
+7 -6

No files matched your search

-3
View File
@@ -1,7 +1,6 @@
const withCss = require('@zeit/next-css')
const withSass = require('@zeit/next-sass')
const { range } = require('lodash')
const fs = require('fs').promises
function createPath(page, map, query, items) {
return items.reduce((acc, path) => {
@@ -24,8 +23,6 @@ module.exports = withCss(withSass({
// secondSecret: process.env.SECOND_SECRET // Pass through env variables
},
exportPathMap: async (defaultPathMap, { dev }) => {
await fs.copyFile('./public/robots.txt', './dist/robots.txt')
if (dev) {
return null
}