platform/packages/file_service/example/main.dart
2024-10-12 03:35:14 -07:00

11 lines
334 B
Dart

import 'package:angel3_file_service/angel3_file_service.dart';
import 'package:angel3_framework/angel3_framework.dart';
import 'package:file/local.dart';
void configureServer(Protevus app) async {
// Just like a normal service
app.use(
'/api/todos',
JsonFileService(const LocalFileSystem().file('todos_db.json')),
);
}