From 774f1a87d8c102ad3754374e53a41b434a01b82c Mon Sep 17 00:00:00 2001 From: pooya parsa Date: Sat, 10 Oct 2020 12:46:08 +0200 Subject: [PATCH] fix(meta): fix `mergeMeta` cjs export --- lib/meta/meta.merge.js | 2 +- lib/meta/module.js | 2 +- lib/meta/plugin.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/meta/meta.merge.js b/lib/meta/meta.merge.js index c00d381f..74b02fbf 100644 --- a/lib/meta/meta.merge.js +++ b/lib/meta/meta.merge.js @@ -1,4 +1,4 @@ -exports.mergeMeta = function mergeMeta (to, from) { +module.exports = function mergeMeta (to, from) { if (typeof to === 'function') { // eslint-disable-next-line no-console console.warn('Cannot merge meta. Avoid using head as a function!') diff --git a/lib/meta/module.js b/lib/meta/module.js index da30a130..fa3d02a6 100755 --- a/lib/meta/module.js +++ b/lib/meta/module.js @@ -1,7 +1,7 @@ const { join, resolve } = require('path') const { existsSync } = require('fs') const { isUrl } = require('../utils') -const { mergeMeta } = require('./meta.merge') +const mergeMeta = require('./meta.merge') module.exports = function nuxtMeta (pwa) { const { nuxt } = this diff --git a/lib/meta/plugin.js b/lib/meta/plugin.js index 1d97fe3b..434d6c1f 100644 --- a/lib/meta/plugin.js +++ b/lib/meta/plugin.js @@ -1,5 +1,5 @@ import meta from './meta.json' -import { mergeMeta } from './meta.merge' +import mergeMeta from './meta.merge' export default function ({ app }) { mergeMeta(app.head, meta)