3307317454
To match Dart style: https://www.dartlang.org/effective-dart/style/#do-use-curly-braces-for-all-flow-control-structures (also, that's the style we use in our .js runtime files, so that will help with diffs of the js->dart runtime migration from https://github.com/dart-lang/dev_compiler/issues/310) BUG= R=jmesserly@google.com Review URL: https://codereview.chromium.org/1524843002 .
17 lines
416 B
JavaScript
Executable File
17 lines
416 B
JavaScript
Executable File
dart_library.library('script', null, /* Imports */[
|
|
"dart/_runtime",
|
|
'dart/core'
|
|
], /* Lazy imports */[
|
|
], function(exports, dart, core) {
|
|
'use strict';
|
|
let dartx = dart.dartx;
|
|
function main(args) {
|
|
let name = args[dartx.join](' ');
|
|
if (name == '') name = 'world';
|
|
core.print(`hello ${name}`);
|
|
}
|
|
dart.fn(main, dart.void, [core.List$(core.String)]);
|
|
// Exports:
|
|
exports.main = main;
|
|
});
|