MCPcopy
hub / github.com/tailwindlabs/tailwindcss / utility

Function utility

packages/tailwindcss/src/compat/plugin-api.test.ts:695–700  ·  view source on GitHub ↗
(name: string, themeKey: string)

Source from the content-addressed store, hash-verified

693 base,
694 module: plugin(function ({ matchUtilities, theme }) {
695 function utility(name: string, themeKey: string) {
696 matchUtilities(
697 { [name]: (value) => ({ '--value': value }) },
698 { values: theme(themeKey) },
699 )
700 }
701
702 utility('my-aspect', 'aspectRatio')
703 utility('my-backdrop-brightness', 'backdropBrightness')

Callers 1

plugin-api.test.tsFile · 0.85

Calls 2

matchUtilitiesFunction · 0.85
themeFunction · 0.85

Tested by

no test coverage detected