MCPcopy
hub / github.com/tailwindlabs/prettier-plugin-tailwindcss / isClassAttr

Function isClassAttr

src/index.ts:311–315  ·  view source on GitHub ↗
(node: { name: string | { type: string; value: string }[] })

Source from the content-addressed store, hash-verified

309 let { matcher } = env
310
311 function isClassAttr(node: { name: string | { type: string; value: string }[] }) {
312 return Array.isArray(node.name)
313 ? node.name.every((n) => n.type === 'TextNode' && matcher.hasStaticAttr(n.value))
314 : matcher.hasStaticAttr(node.name)
315 }
316
317 function hasSurroundingQuotes(str: string) {
318 let start = str[0]

Callers 2

AttrSingleQuotedFunction · 0.85
AttrDoubleQuotedFunction · 0.85

Calls 1

hasStaticAttrMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…