Skip to content

Commit aa979d6

Browse files
committed
ensure we fallback to '' for backwards compatibility reasons
1 parent bf28bf6 commit aa979d6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib/setupContextUtils.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,11 @@ function buildPluginApi(tailwindConfig, context, { variantList, variantMap, offs
608608
}
609609

610610
return variantFn(
611-
args?.value === sharedState.NONE ? options.values.DEFAULT : args?.value,
611+
args?.value === sharedState.NONE
612+
? options.values.DEFAULT
613+
: // Falling back to args if it is a string, otherwise '' for older intellisense
614+
// (JetBrains) plugins.
615+
args?.value ?? (typeof args === 'string' ? args : ''),
612616
modifiersEnabled ? { modifier: args?.modifier, container } : { container }
613617
)
614618
},

0 commit comments

Comments
 (0)