Skip to Content
Mix logo

Flutter styling withoutthe boilerplate.

Fluent, chainable styles. Reactive variants. Design tokens. Build design systems that scale.

Why Mix

Less nesting. More clarity.

Without Mix
Container(
  padding: EdgeInsets.all(16),
  decoration: BoxDecoration(
    color: Colors.blue,
    borderRadius:
      BorderRadius.circular(8),
  ),
  child: ...
)
With Mix
// Style can live outside the widget
final cardStyle = BoxStyler()
    .color(Colors.blue)
    .padding(.all(16))
    .borderRadius(.circular(8));

// Widget stays clean
Box(style: cardStyle, child: ...)
Features

Style composition, reactive variants, and design tokens — in one package.

Mix uses Dart's type system to make styles composable and type-safe. Chain methods to build styles, compose them with variants, and let the framework handle the rest.

Intuitive Styling

Define size, color, and shape in a single fluent chain. Each method returns a new style — readable, composable, and type-safe.

See the styling guide
Loading source...
Waiting...

Context-Reactive Variants

Declare hover behavior inline — color, scale, and shadow all react to state without conditional logic.

Explore variants
Loading source...
Waiting...

Powerful Animations

Define keyframe timelines with multiple property tracks directly inside styles. No external animation controllers needed.

Animation docs
Loading source...
Waiting...

Design System Buttons

Define a base button once, then compose variants by adding just what differs. Text styling flows through via inherited defaults.

Build your own widget
Loading source...
Waiting...

Text Directives

Apply uppercase and capitalize transforms directly in the style. Directives stay attached through merges and composition.

Directives guide
Loading source...
Waiting...
Code generation

Turn a Styler into a widget API.

Annotate the style you already use. Mix generates a typed StatelessWidget that is ready for layouts, const constructors, and your design system's public API.

AppCard code generation
@MixWidget()AppCard
app_card.dartYou write
@MixWidget()
final appCardStyle = BoxStyler()
    .color(Colors.deepPurple)
    .paddingAll(16)
    .borderRounded(12);
app_card.g.dartGenerated
class AppCard extends StatelessWidget {
  const AppCard({super.key, this.child});

  final Widget? child;

  @override
  Widget build(BuildContext context) {
    return appCardStyle.call(
      key: this.key,
      child: this.child,
    );
  }
}
03 / Use it

Compose it anywhere.

const AppCard(
  child: Text(
    'A real Flutter widget',
  ),
);
See the annotation and generated Dart
Get Started

Add Mix to your project.

$flutter pub add mix

Ready to build?

Start building your first Mix-styled widget in under 5 minutes.