From 3feb54cfa20db3ed39b8a32e430b4ea3508eda8a Mon Sep 17 00:00:00 2001 From: Gajus Kuizinas Date: Sun, 29 Jul 2018 12:50:40 +0100 Subject: [PATCH] fix: add a workaround for ESLint < v5 --- src/rules/no-cycle.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/rules/no-cycle.js b/src/rules/no-cycle.js index a925f9871..1a70db2c7 100644 --- a/src/rules/no-cycle.js +++ b/src/rules/no-cycle.js @@ -34,6 +34,10 @@ module.exports = { return // no Flow import resolution } + if (sourceNode._babelType === 'Literal') { + return // no Flow import resolution, workaround for ESLint < 5.x + } + if (imported == null) { return // no-unresolved territory }