edge_dart_runtime 0.0.1 copy "edge_dart_runtime: ^0.0.1" to clipboard
edge_dart_runtime: ^0.0.1 copied to clipboard

A Edge runtime dart.

example/lib/main.dart

import 'package:edge_dart_runtime/edge_dart_runtime.dart';
import 'package:http/http.dart' as http;

void main() {
  // Setup the runtime environment.
  setupRuntime();
}

/// A fetch event handler.
Future<Response> fetchHandler(Request request) async {
  print('do request');
  final r =
      await http.get(Uri.parse('https://jsonplaceholder.typicode.com/todos/1'));
  print(r.body);

  return Response('Hello, world!!', status: 200);
}
1
likes
70
points
312
downloads

Publisher

unverified uploader

Weekly Downloads

A Edge runtime dart.

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

freezed_annotation, js, typings

More

Packages that depend on edge_dart_runtime