add support for config files with .cjs extension (#198)

master
Brad Cornes 2020-12-08 13:26:02 +00:00
parent e530f03739
commit f9865fb219
2 changed files with 2 additions and 2 deletions

View File

@ -36,7 +36,7 @@
},
"icon": "media/icon.png",
"activationEvents": [
"workspaceContains:**/{tailwind,tailwind.config,tailwind-config,.tailwindrc}.js"
"workspaceContains:**/{tailwind,tailwind.config,tailwind-config,.tailwindrc}.{js,cjs}"
],
"main": "dist/extension/index.js",
"contributes": {

View File

@ -24,7 +24,7 @@ function arraysEqual(arr1, arr2) {
}
const CONFIG_GLOB =
'**/{tailwind,tailwind.config,tailwind-config,.tailwindrc}.js'
'**/{tailwind,tailwind.config,tailwind-config,.tailwindrc}.{js,cjs}'
export default async function getClassNames(
cwd = process.cwd(),