Files
Luan Nico b79fee0ae2 chore: Update min Dart constraint to 3.8 (#3676)
Update min Dart constraint to 3.8, which will enable us to use the
fancier collection literals.

This requires bumping the min Flutter version as well:

<img width="1892" height="1122" alt="image"
src="https://github.com/user-attachments/assets/7c7b07fc-4d96-4987-824d-9a7133ecfb85"
/>
2025-08-10 12:42:31 -04:00

32 lines
1020 B
Dart

import 'package:flutter/widgets.dart';
import 'package:tutorials_space_shooter/step1/main.dart' as step1;
import 'package:tutorials_space_shooter/step2/main.dart' as step2;
import 'package:tutorials_space_shooter/step3/main.dart' as step3;
import 'package:tutorials_space_shooter/step4/main.dart' as step4;
import 'package:tutorials_space_shooter/step5/main.dart' as step5;
import 'package:tutorials_space_shooter/step6/main.dart' as step6;
import 'package:web/web.dart' as web;
void main() {
var page = web.window.location.search;
if (page.startsWith('?')) {
page = page.substring(1);
}
return switch (page) {
'step1' => step1.main(),
'step2' => step2.main(),
'step3' => step3.main(),
'step4' => step4.main(),
'step5' => step5.main(),
'step6' => step6.main(),
_ => runApp(
Directionality(
textDirection: TextDirection.ltr,
child: Text('''Error: unknown page. Pass "step{1,6}" as a GET param;
e.g: ${web.window.location}?step1'''),
),
),
};
}