| Index: pkg/polymer/lib/src/emitters.dart
|
| diff --git a/pkg/polymer/lib/src/emitters.dart b/pkg/polymer/lib/src/emitters.dart
|
| index 2e4e008f472d83b28768a32490695fd22086f714..dbd6816ab60a7119fc540b9173310465c07dfad6 100644
|
| --- a/pkg/polymer/lib/src/emitters.dart
|
| +++ b/pkg/polymer/lib/src/emitters.dart
|
| @@ -49,10 +49,6 @@ NestedPrinter generateBootstrapCode(
|
| ..addLine('')
|
| ..addLine("import 'package:polymer/polymer.dart';")
|
| ..addLine("import 'dart:mirrors' show currentMirrorSystem;");
|
| - if (userMainInfo.userCode != null) {
|
| - printer..addLine("import '${pathMapper.importUrlFor(info, userMainInfo)}' "
|
| - "as userMain;\n");
|
| - }
|
|
|
| int i = 0;
|
| for (var c in global.components.values) {
|
| @@ -60,6 +56,10 @@ NestedPrinter generateBootstrapCode(
|
| printer.addLine("import '${pathMapper.importUrlFor(info, c)}' as i$i;");
|
| i++;
|
| }
|
| + if (userMainInfo.userCode != null) {
|
| + printer..addLine("import '${pathMapper.importUrlFor(info, userMainInfo)}' "
|
| + "as i$i;\n");
|
| + }
|
|
|
| printer..addLine('')
|
| ..addLine('void main() {')
|
| @@ -72,10 +72,13 @@ NestedPrinter generateBootstrapCode(
|
| printer.addLine("'${pathMapper.importUrlFor(info, c)}',");
|
| }
|
|
|
| + if (userMainInfo.userCode != null) {
|
| + printer.addLine("'${pathMapper.importUrlFor(info, userMainInfo)}',");
|
| + }
|
| +
|
| return printer
|
| ..indent -= 1
|
| ..addLine('],')
|
| - ..addLine(userMainInfo.userCode != null ? 'userMain.main,' : '() {},')
|
| ..addLine(
|
| "currentMirrorSystem().findLibrary(const Symbol('app_bootstrap'))")
|
| ..indent += 2
|
|
|