Skip to content

Commit 83a003f

Browse files
authored
add './content/**/*.{md,mdx}' to Tailwind CSS config (#666)
1 parent ef4d681 commit 83a003f

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

.changeset/stale-files-give.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@theguild/tailwind-config': patch
3+
---
4+
5+
add `'./content/**/*.{md,mdx}'` to Tailwind CSS config

packages/tailwind-config/src/tailwind.config.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function getComponentsPatterns() {
3333
path.relative(process.cwd(), path.posix.join(componentsPackageJson, '..', 'dist/**/*.js')),
3434
];
3535
} catch {
36-
console.warn("Can't find `@theguild/components` package.")
36+
console.warn("Can't find `@theguild/components` package.");
3737
return [];
3838
}
3939
}
@@ -44,7 +44,12 @@ const config = {
4444
* @see https://github.com/tailwindlabs/tailwindcss/pull/12717/files#diff-cf9185e083748e39c6940d3ad337df23b0ecbbd70b9550f596de7cf4b4668bcfR263-R273
4545
*/
4646
darkMode: ['variant', '&:not(.light *)'],
47-
content: ['./{src,app}/**/*.{tsx,mdx}', './mdx-components.tsx', ...getComponentsPatterns()],
47+
content: [
48+
'./{src,app}/**/*.{tsx,mdx}',
49+
'./mdx-components.tsx',
50+
'./content/**/*.{md,mdx}',
51+
...getComponentsPatterns(),
52+
],
4853
theme: {
4954
container: {
5055
center: true,

0 commit comments

Comments
 (0)