From abaeaa48984b3bcb551c92983dd01434dff0d746 Mon Sep 17 00:00:00 2001 From: Constance Chen Date: Thu, 18 Aug 2022 11:14:35 -0700 Subject: [PATCH] Add dev documentation on how to disable the lint rule for specific properties --- scripts/eslint-plugin/css_logical_properties.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/eslint-plugin/css_logical_properties.js b/scripts/eslint-plugin/css_logical_properties.js index af0999bb03a..c301a658854 100644 --- a/scripts/eslint-plugin/css_logical_properties.js +++ b/scripts/eslint-plugin/css_logical_properties.js @@ -32,6 +32,12 @@ module.exports = { 'Prefer the CSS logical value for {{ property }} - @see src/global_styling/functions/logicals.ts', }, fixable: 'code', + // NOTE: To disable this lint rule for a single line/property within a css`` block + // your code must use a comment inside a template literal, e.g.: + // css` + // color: red; + // height: 40px; ${/* eslint-disable-line local/css-logical-properties */ ''} + // ` }, create: function (context) { return {