From 576f1438ee6684df8fd6f4fbf1645e9b2e509fd5 Mon Sep 17 00:00:00 2001 From: Hannah Wolfe Date: Wed, 26 May 2021 12:34:39 +0100 Subject: [PATCH] Upgraded no-restricted-require in shared rule to error - We should not require server or frontend files inside the shared libraries as these are intended to be required FROM the server and frontend components - Now that we've resolved the two outstanding warnings, make this an error so we can't regress on this easily --- .eslintrc.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.eslintrc.js b/.eslintrc.js index a7e2aa0d47..a53c92d735 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -31,7 +31,7 @@ module.exports = { { files: 'core/shared/**', rules: { - 'ghost/node/no-restricted-require': ['warn', [ + 'ghost/node/no-restricted-require': ['error', [ { name: path.resolve(__dirname, 'core/server/**'), message: 'Invalid require of core/server from core/shared.'