From 417ee19c1d183e9f66791cdd74055e0f7fab5d03 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:03:25 -0600 Subject: [PATCH] rewrite svg: w/ new addVariant API https://github.com/tailwindlabs/tailwindcss/pull/5809 --- tailwind.config.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/tailwind.config.js b/tailwind.config.js index 6aac9be10..5dd2bfa2b 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -74,13 +74,7 @@ module.exports = { plugins: [ // imitation of the twin.macro svg: variant. svg:text-green-500 puts green // on an SVG that's an immediate child of the element - plugin(function ({ addVariant, e }) { - addVariant('svg', ({ modifySelectors, separator }) => { - modifySelectors( - ({ className }) => `.${e(`svg${separator}${className}`)} > svg` - ) - }) - }), + plugin(({ addVariant }) => addVariant('svg', '& > svg')), childrenPlugin, ], /**