cruky 0.6.0 copy "cruky: ^0.6.0" to clipboard
cruky: ^0.6.0 copied to clipboard

discontinuedreplaced by: croky
outdated

cruky is server-side library to create API with modern and fast performance.

example/main.dart

import 'package:cruky/cruky.dart';

void main() => run(MyApp());

class MyApp extends AppMaterial {
  @override
  List get routes => [
        exampleWithGETRequest,
      ];

  @override
  List get middlewares => [middlewareExample];
}

@Route.get('/')
exampleWithGETRequest(ReqCTX req) {
  return Json({});
}

@BeforeMW()
middlewareExample(ReqCTX req) {
  if (req.headerValue('Token') == null) {
    return Text('Not Auth', 401);
  }
}
1
likes
0
pub points
0%
popularity

Publisher

unverified uploader

cruky is server-side library to create API with modern and fast performance.

Repository (GitHub)
View/report issues

Documentation

Documentation

License

unknown (LICENSE)

Dependencies

mime, path

More

Packages that depend on cruky