diff --git a/src/jit/lib/setupContextUtils.js b/src/jit/lib/setupContextUtils.js index 1b35fa405..2506d37ad 100644 --- a/src/jit/lib/setupContextUtils.js +++ b/src/jit/lib/setupContextUtils.js @@ -478,8 +478,9 @@ export function getContext( getTailwindConfig ) { let sourcePath = result.opts.from - let [tailwindConfig, userConfigPath, tailwindConfigHash, configDependencies] = - getTailwindConfig(configOrPath) + let [tailwindConfig, userConfigPath, tailwindConfigHash, configDependencies] = getTailwindConfig( + configOrPath + ) let isConfigFile = userConfigPath !== null let contextDependencies = new Set(configDependencies) @@ -581,6 +582,11 @@ export function getContext( stylesheetCache: null, // Hit } + if (!existingContext) { + // If we didn't have an existing modified map then populate it now. + trackModified([...contextDependencies], context) + } + // --- // Update all context tracking state