Skip to main content

enableTailwind()

available from v3.3.95

A function that modifies the default Webpack configuration to make the necessary changes to support TailwindCSS.

remotion.config.ts
ts
import { Config } from "@remotion/cli/config";
import { enableTailwind } from "@remotion/tailwind";
 
Config.overrideWebpackConfig((currentConfiguration) => {
return enableTailwind(currentConfiguration);
});
remotion.config.ts
ts
import { Config } from "@remotion/cli/config";
import { enableTailwind } from "@remotion/tailwind";
 
Config.overrideWebpackConfig((currentConfiguration) => {
return enableTailwind(currentConfiguration);
});

If you want to make other configuration changes, you can do so by doing them reducer-style:

remotion.config.ts
ts
import { Config } from "@remotion/cli/config";
import { enableTailwind } from "@remotion/tailwind";
 
Config.overrideWebpackConfig((currentConfiguration) => {
return enableTailwind({
...currentConfiguration,
 
// Make other changes
});
});
remotion.config.ts
ts
import { Config } from "@remotion/cli/config";
import { enableTailwind } from "@remotion/tailwind";
 
Config.overrideWebpackConfig((currentConfiguration) => {
return enableTailwind({
...currentConfiguration,
 
// Make other changes
});
});

See the setup to see full instructions on how to setup TailwindCSS in Remotion.