platform/packages/hot/example/main.dart

14 lines
329 B
Dart
Raw Normal View History

import 'dart:io';
2021-05-15 13:17:18 +00:00
import 'package:angel3_hot/angel3_hot.dart';
import 'server.dart';
2017-06-06 12:07:59 +00:00
2021-05-01 02:57:26 +00:00
void main() async {
2019-05-01 09:51:27 +00:00
var hot = HotReloader(createServer, [
Directory('src'),
'server.dart',
// Also allowed: Platform.script,
2021-05-15 13:17:18 +00:00
Uri.parse('package:angel3_hot/angel3_hot.dart')
]);
await hot.startServer('127.0.0.1', 3000);
}