AngularDart 4与Dart 2兼容吗? build_runner 0.8?

时间:2018-04-23 19:32:56

标签: dart angular-dart

目前正在

  • Dart VM版本:2.0.0-dev.49.0
  • angular ^ 4.0.0
  • 的Linux
  • Dartium

Dart 2升级@ https://webdev-dartlang-org-dev.firebaseapp.com/dart-2的升级要求之一是使用build_runner 0.8,错误代码与Angular4不兼容。

我的pubspec.yaml看起来像

name: JRapha
description: A web app that uses AngularDart Components
version: 0.0.1
environment:
  sdk: '>=2.0.0-dev.49.0 <2.0.0'
dependencies:
  angular: ^4.0.0
dev_dependencies:
  angular_test: ^1.0.0
  test: ^0.12.30
  build_runner: ^0.8.2
  build_test: ^0.10.1
  build_web_compilers: ^0.3.6
web:
  compiler:
    debug: dartdevc

运行pub get

时出错

Because angular_compiler >=0.2.1 <0.3.0+1 depends on build ^0.10.0 and no versions of angular_compiler match >0.3.0+1 <0.4.0, angular_compiler >=0.2.1 <0.3.0+1 or >0.3.0+1 <0.4.0 requires build ^0.10.0. And because angular >=4.0.0-beta <5.0.0-alpha depends on angular_compiler ^0.3.0, angular >=4.0.0-beta <5.0.0-alpha requires build ^0.10.0 or angular_compiler 0.3.0+1. And because angular_compiler 0.3.0+1 depends on build >=0.10.0 <0.12.0 and build_web_compilers >=0.2.1 depends on build ^0.12.0, angular >=4.0.0-beta <5.0.0-alpha is incompatible with build_web_compilers >=0.2.1. So, because JRapha depends on both angular ^4.0.0 and build_web_compilers ^0.3.6, version solving failed.

是否有使用Dart v2运行AngularDart4的解决方案?

1 个答案:

答案 0 :(得分:4)

不,它不兼容。

只有AngularDart v5与Dart2和} 兼容。