File tree Expand file tree Collapse file tree 1 file changed +31
-12
lines changed
packages/tailwindcss-language-server/src Expand file tree Collapse file tree 1 file changed +31
-12
lines changed Original file line number Diff line number Diff line change @@ -232,7 +232,7 @@ testFixture('v4/invalid-import-order', [
232
232
// ---
233
233
234
234
testLocator ( {
235
- name : 'Sass files are not supported detected with v4' ,
235
+ name : 'Sass files are not detected with v4' ,
236
236
fs : {
237
237
'package.json' : json `
238
238
{
@@ -248,18 +248,35 @@ testLocator({
248
248
@use 'tailwindcss';
249
249
` ,
250
250
} ,
251
+ expected : [ ] ,
252
+ } )
251
253
252
- // We want to ignore `node_modules` folders otherwise we'll pick up the
253
- // default Tailwind CSS `index.css` file as a CSS-based config.
254
- settings : {
255
- tailwindCSS : {
256
- files : {
257
- exclude : [ '**/node_modules' ] ,
258
- } ,
259
- } as any ,
254
+ testLocator ( {
255
+ name : 'Sass files are detected with v3' ,
256
+ fs : {
257
+ 'package.json' : json `
258
+ {
259
+ "dependencies": {
260
+ "tailwindcss": "^3.4.17"
261
+ }
262
+ }
263
+ ` ,
264
+ 'tailwind.admin.config.js' : js `
265
+ module.exports = {
266
+ content: ['./src/**/*.{html,js}'],
267
+ }
268
+ ` ,
269
+ 'src/app.scss' : scss `
270
+ @config '../tailwind.admin.config.js';
271
+ ` ,
260
272
} ,
261
-
262
- expected : [ ] ,
273
+ expected : [
274
+ {
275
+ version : '3.4.17' ,
276
+ config : '/tailwind.admin.config.js' ,
277
+ content : [ '/src/**/*.{html,js}' ] ,
278
+ } ,
279
+ ] ,
263
280
} )
264
281
265
282
// ---
@@ -303,7 +320,9 @@ async function prepare({ root }: TestUtils) {
303
320
let defaultSettings = {
304
321
tailwindCSS : {
305
322
files : {
306
- exclude : [ ] ,
323
+ // We want to ignore `node_modules` folders otherwise we'll pick up
324
+ // configs from there and we don't want that.
325
+ exclude : [ '**/node_modules' ] ,
307
326
} ,
308
327
} ,
309
328
} as Settings
You can’t perform that action at this time.
0 commit comments