Skip to content
pubscout

slang_build_runner

4.19.0, released 3 months ago by tienisto.com

build_runner integration for slang translation generation

$ flutter pub add slang_build_runner
Source repository

What it does

Integrates the slang translation library into the standard Dart build_runner pipeline. It enables developers to generate type-safe localization files alongside other code generation tools. Configuration is handled through build.yaml instead of slang.yaml.

AI-written summary of version 4.19.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You use slang for translations and already use build_runner for other code generators
  • You want a unified single-command build step for all project code generation

Skip it when

  • You do not use build_runner and prefer slang's standalone CLI tool
  • You are not using slang for localization

Strengths

  • Combines translation generation into existing build_runner pipelines
  • Includes a legacy fallback builder if build_runner asset writer issues occur
  • Supports standard build.yaml builder configuration

Weaknesses

  • The default builder has known issues with asset writing in some build configurations
  • The legacy builder does not support build_runner build --workspace

Setup

Kind
Pure Dart
Effort
Low
Code generation
Yes (build_runner)
Direct dependencies
4

Requires dev_dependencies on build_runner and slang_build_runner, configuration in build.yaml, and running build_runner build.

targets:
  $default:
    builders:
      slang_build_runner:
        options:
          base_locale: en

Works with

Packages commonly used together with slang_build_runner: ones it builds on, ones built on it, and its own family.