From e82289bff202f8dacd6bdf7166c2cb955425bcac Mon Sep 17 00:00:00 2001 From: Shawn Erquhart Date: Fri, 27 Jul 2018 11:50:04 -0400 Subject: [PATCH] fix: fix version console log (#1528) --- packages/netlify-cms-core/src/bootstrap.js | 2 +- scripts/webpack.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/netlify-cms-core/src/bootstrap.js b/packages/netlify-cms-core/src/bootstrap.js index 3c9c0ee4..fc33fea2 100644 --- a/packages/netlify-cms-core/src/bootstrap.js +++ b/packages/netlify-cms-core/src/bootstrap.js @@ -20,7 +20,7 @@ function bootstrap(opts = {}) { /** * Log the version number. */ - console.log(`Netlify CMS version ${process.env.NETLIFY_CMS_VERSION}`); + console.log(`Netlify CMS version ${NETLIFY_CMS_VERSION}`); /** * Get DOM element where app will mount. diff --git a/scripts/webpack.js b/scripts/webpack.js index 4f9858da..a21637ab 100644 --- a/scripts/webpack.js +++ b/scripts/webpack.js @@ -26,7 +26,7 @@ const rules = () => ({ const plugins = () => { return { define: () => new webpack.DefinePlugin({ - NETLIFY_CMS_VERSION: `${pkg.version}${isProduction ? '' : '-dev'}`, + NETLIFY_CMS_VERSION: JSON.stringify(`${pkg.version}${isProduction ? '' : '-dev'}`), }), ignoreEsprima: () => new webpack.IgnorePlugin(/^esprima$/, /js-yaml/), ignoreMomentOptionalDeps: () => new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),