spry_static 1.1.1 copy "spry_static: ^1.1.1" to clipboard
spry_static: ^1.1.1 copied to clipboard

Static files handler support for Spry and ecosystem.

Spry Static #

spry_static is a Handle/Middleware for the Dart Spry framework.

pub package

Installation #

Add spry_static to your pubspec.yaml:

dependencies:
  spry_static: any

Or install it from the command line:

dart pub add spry_static

Example #

import 'package:spry/spry.dart';
import 'package:spry_static/spry_static.dart';

void main() async {
  final Spry spry = Spry();
  final Static static = Static.directory(
    directory: 'static',
    defaultFiles: ['index.html'],
  );

  await spry.listen(static, port: 3000);
  print('Listening on port http://localhost:3000');
}
0
likes
140
points
35
downloads

Publisher

verified publisherodroe.com

Weekly Downloads

Static files handler support for Spry and ecosystem.

Documentation

API reference

License

MIT (license)

Dependencies

mime, path, prexp, spry

More

Packages that depend on spry_static