jet 0.0.1

Jet #

Jet leverages the powerful features of the Dart programming language and fuses them with functional concepts to provide a lightweight fabric for building fast and performant web applications.

Example #

Using the Jet application interface, you can get your web application up and running in no time. Here's a simple example.

import 'dart:async';

import 'package:jet/jet.dart';

class Example implements Middleware {
  @override
  Future<Context> resolve(Context context, Resolver next) async => context
    .setResponse(Response.text('Hello, Jet!'));
}

Future main() async => listen(middleware: [
  Example()
]);

To run this example, simply paste the code into a file and let Dart evaluate it. You should then be able to fire up your favorite browser and navigate to localhost:9000 to see the example application in action.

Changelog #

0.0.1 #

  • Initial release.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  jet: ^0.0.1

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter pub get

Alternatively, your editor might support pub get or flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:jet/jet.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
0
Health:
Code health derived from static analysis. [more]
99
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
80
Overall:
Weighted score of the above. [more]
46
Learn more about scoring.

We analyzed this package on Aug 16, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.4.0
  • pana: 0.12.19

Platforms

Detected platforms: Flutter, other

Primary library: package:jet/jet.dart with components: io.

Health issues and suggestions

Document public APIs. (-1 points)

38 out of 38 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Fix lib/src/server.dart. (-0.50 points)

Analysis of lib/src/server.dart reported 1 hint:

line 45 col 9: Future results in async function bodies must be awaited or marked unawaited using package:pedantic.

Format lib/src/context.dart.

Run dartfmt to format lib/src/context.dart.

Format lib/src/middleware.dart.

Run dartfmt to format lib/src/middleware.dart.

Format lib/src/request.dart.

Run dartfmt to format lib/src/request.dart.

Format lib/src/response.dart.

Run dartfmt to format lib/src/response.dart.

Maintenance suggestions

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and jet.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
built_collection ^4.0.0 4.2.2
Transitive dependencies
collection 1.14.12
matcher 0.12.5
meta 1.1.7
path 1.6.4
quiver 2.0.5
stack_trace 1.9.3