File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change 1+ ## 6.12.0-wip
2+
3+ - Allow an option called ` run_only_if_triggered ` so it can be used by
4+ ` build_runner ` .
5+
16## 6.11.1
27
38- Allow ` build: '>=3.0.0 <5.0.0' ` .
Original file line number Diff line number Diff line change @@ -23,7 +23,12 @@ import 'src/json_part_builder.dart';
2323/// Not meant to be invoked by hand-authored code.
2424Builder jsonSerializable (BuilderOptions options) {
2525 try {
26- final config = JsonSerializable .fromJson (options.config);
26+ var configJson = options.config;
27+ // Ignore `run_only_if_triggered` if present, it's used by `build_runner`.
28+ if (configJson.containsKey ('run_only_if_triggered' )) {
29+ configJson = Map .of (configJson)..remove ('run_only_if_triggered' );
30+ }
31+ final config = JsonSerializable .fromJson (configJson);
2732 return jsonPartBuilder (config: config);
2833 } on CheckedFromJsonException catch (e) {
2934 final lines = < String > [
You can’t perform that action at this time.
0 commit comments