Example app: Add explanatory comment to copy builder

This commit is contained in:
Simon Binder 2022-06-03 23:18:23 +02:00
parent 6a6d1268c4
commit 429d36ff9c
No known key found for this signature in database
GPG Key ID: 7891917E4147B8C0
2 changed files with 5 additions and 2 deletions

View File

@ -36,12 +36,12 @@ targets:
# Configuring this builder isn't required for most apps. In our case, we
# want to compile the web worker in `web/worker.dart` to JS and we use the
# build system for that.
build_web_compilers|entrypoint:
build_web_compilers:entrypoint:
generate_for:
- web/worker.dart
options:
compiler: dart2js
"|copy_compiled_worker_js":
":copy_compiled_worker_js":
enabled: true

View File

@ -1,5 +1,8 @@
import 'package:build/build.dart';
/// Builder that copies the (hidden, `build_to: cache`) output of
/// `build_web_compilers` into `web/` (visible, this builder is defined with
/// `build_to: source`).
class CopyCompiledJs extends Builder {
CopyCompiledJs([BuilderOptions? options]);