简体   繁体   English

如何配置Dart编辑器以构建“ .UXL”文件

[英]How to configure Dart Editor to build “.UXL” files

I have the demo code for the Rikulo UXL ScrollView demo working with the Dart Editor. 我有使用Dart Editor的Rikulo UXL ScrollView演示的演示代码。

However, the set-up seems cumbersome to me. 但是,设置对我来说似乎很麻烦。 For the example to build the .Dart file from the UXL file, ( apparently ) it needs to be named as: "ScrollView.uxl.xml". 对于从UXL文件构建.Dart文件的示例,( 显然 )它需要命名为:“ ScrollView.uxl.xml”。 Can the build process or Dart Editor be configured and set-up to do a more streamlined workflow like: 可以配置和设置构建过程或Dart编辑器以执行更简化的工作流程,例如:

ScrollView.uxl --> ScrollView.dart

As opposed to the current rule: 与当前规则相反:

ScrollView.uxl.xml --> ScrollView.uxl.dart

It seem to me the solution seems to lie in the UXL builder: 在我看来,解决方案似乎在于UXL构建器中:

import 'package:rikulo_uxl/uc.dart'; 导入'package:rikulo_uxl / uc.dart';

Solutions welcome. 欢迎解决方案。

The readme of the package seems to contain exactly the code you are looking for: 软件包的自述文件似乎完全包含您要查找的代码:

https://github.com/rikulo/uxl https://github.com/rikulo/uxl

add this to your build.dart file (in the directory where your pubspec.yaml file is 添加到您的build.dart文件(目录在您pubspec.yaml文件

import 'package:rikulo_uxl/uc.dart' show build;

void main(List<String> arguments) {
    build(arguments);
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM