-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.closed-obsoleteClosed as the reported issue is no longer relevantClosed as the reported issue is no longer relevanttype-enhancementA request for a change that isn't a bugA request for a change that isn't a bug
Description
This issue was originally filed by @sethladd
Consider this code:
import 'dart:html';
import 'dart:async';
@lazy
import 'reverser.dart';
const lazy = const DeferredLibrary('reverser', uri: './part.js');
void main() {
print('in main');
new Timer(const Duration(seconds:3), () {
lazy.load().then((_) {
print('library loaded');
query("#sample_text_id")
..text = "Click me!"
..onClick.listen(reverseText);
});
});
}
void reverseText(MouseEvent event) {
query("#sample_text_id").text = reverse(query("#sample_text_id").text);
}
In the network panel of Dev Tools, I see the request for reverser.dart immediately on page load. I was expecting now to see the request until after the Timer fires.
Metadata
Metadata
Assignees
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.closed-obsoleteClosed as the reported issue is no longer relevantClosed as the reported issue is no longer relevanttype-enhancementA request for a change that isn't a bugA request for a change that isn't a bug