From e8173a1e858886b5d77e4f16856ca343e2323b94 Mon Sep 17 00:00:00 2001 From: Daniel Sil Date: Mon, 20 Nov 2023 12:34:10 +0100 Subject: [PATCH] chore: improve eslint tailwind config --- .eslintrc.cjs | 5 +++++ packages/orbit-components/.eslintrc.cjs | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/.eslintrc.cjs b/.eslintrc.cjs index 2de949407b..2638bfc2fc 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -13,6 +13,11 @@ module.exports = { reportUnusedDisableDirectives: true, extends: CONFIGS, plugins: ["@babel"], + settings: { + tailwindcss: { + callees: ["cx", "clsx"], + }, + }, rules: { "no-console": ["error", { allow: ["warn", "error"] }], "no-unused-expressions": "off", diff --git a/packages/orbit-components/.eslintrc.cjs b/packages/orbit-components/.eslintrc.cjs index d47c56208a..fdc81e54e4 100644 --- a/packages/orbit-components/.eslintrc.cjs +++ b/packages/orbit-components/.eslintrc.cjs @@ -1,4 +1,5 @@ const path = require("path"); +const orbitPreset = require("@kiwicom/orbit-tailwind-preset"); module.exports = { extends: ["../../.eslintrc.cjs", "plugin:storybook/recommended"], @@ -13,6 +14,11 @@ module.exports = { env: { browser: true, }, + settings: { + tailwindcss: { + config: orbitPreset(), + }, + }, overrides: [ { files: ["cypress/**/*.ts?(x)", "config/**/*.mts"],