plugins.test.ts — tailwindcss Source File
Architecture documentation for plugins.test.ts, a typescript file in the tailwindcss codebase. 3 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR c2e1e558_884b_66e4_d597_6c15d2488811["plugins.test.ts"] 9ffd1dda_9675_c514_373d_0f4ab4648249["utils.ts"] c2e1e558_884b_66e4_d597_6c15d2488811 --> 9ffd1dda_9675_c514_373d_0f4ab4648249 b7531519_9055_fbfa_5f69_ebc8586b0422["candidate"] c2e1e558_884b_66e4_d597_6c15d2488811 --> b7531519_9055_fbfa_5f69_ebc8586b0422 f11e3be9_51f8_140b_68b0_f58ddd082595["test"] c2e1e558_884b_66e4_d597_6c15d2488811 --> f11e3be9_51f8_140b_68b0_f58ddd082595 style c2e1e558_884b_66e4_d597_6c15d2488811 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { candidate, css, html, js, json, test } from '../utils'
test(
'builds the `@headlessui/tailwindcss` plugin utilities (CJS)',
{
fs: {
'package.json': json`
{
"type": "commonjs",
"dependencies": {
"postcss": "^8",
"postcss-cli": "^10",
"tailwindcss": "workspace:^",
"@tailwindcss/postcss": "workspace:^",
"@headlessui/tailwindcss": "^0.2.1"
}
}
`,
'postcss.config.cjs': js`
let tailwindcss = require('@tailwindcss/postcss')
module.exports = {
plugins: [tailwindcss()],
}
`,
'index.html': html`
<div className="ui-open:flex"></div>
`,
'src/index.css': css`
@reference 'tailwindcss/theme';
@import 'tailwindcss/utilities';
@plugin '@headlessui/tailwindcss';
`,
},
},
async ({ fs, exec }) => {
await exec('pnpm postcss src/index.css --output dist/out.css')
await fs.expectFileToContain('dist/out.css', [candidate`ui-open:flex`])
},
)
test(
'builds the `@headlessui/tailwindcss` plugin utilities (ESM)',
{
fs: {
'package.json': json`
{
"type": "module",
"dependencies": {
"postcss": "^8",
"postcss-cli": "^10",
"tailwindcss": "workspace:^",
"@tailwindcss/postcss": "workspace:^",
"@headlessui/tailwindcss": "^0.2.1"
}
}
`,
'postcss.config.mjs': js`
import tailwindcss from '@tailwindcss/postcss'
export default {
plugins: [tailwindcss()],
}
`,
'index.html': html`
<div className="ui-open:flex"></div>
`,
'src/index.css': css`
@reference 'tailwindcss/theme';
@import 'tailwindcss/utilities';
@plugin '@headlessui/tailwindcss';
`,
},
},
async ({ fs, exec }) => {
await exec('pnpm postcss src/index.css --output dist/out.css')
await fs.expectFileToContain('dist/out.css', [candidate`ui-open:flex`])
},
)
Domain
Source
Frequently Asked Questions
What does plugins.test.ts do?
plugins.test.ts is a source file in the tailwindcss codebase, written in typescript. It belongs to the OxideEngine domain.
What does plugins.test.ts depend on?
plugins.test.ts imports 3 module(s): candidate, test, utils.ts.
Where is plugins.test.ts in the architecture?
plugins.test.ts is located at integrations/postcss/plugins.test.ts (domain: OxideEngine, directory: integrations/postcss).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free