oxide 0.3.3

  • Readme
  • Changelog
  • Example
  • Installing
  • 50

Oxide #

Extremely simple and easy to use web framework for Dart

Features #

  • Easy to use server framework
  • Annotation based route system
  • Least abstraction possible allowing flexibility

Comparison To Other Frameworks #

  • Made especially for native / vm
  • Uses annotations and mirrors to make creating routes clean
  • Extremely small code base to reduce bundle/compilation size
  • Built on top of dart nightly but backwards compatible

Stability over complexity #

While more features is nice and all, it adds complexity, and thus is more error prone.
Oxide aims to avoid this by making the code base as small and abstraction-less as possible.
The goal of oxide is stability and flexibility not to be extremely feature-full.

Oxide Changelog #

Version 0.1.0 #

  • Created route class
  • Created method enum
  • Created utility functions to get metadata from route functions
  • Created basic oxide server

Version 0.1.1 #

  • Patched the pubspec file with the correct SDK version

Version 0.2.0-dev.1 #

  • Rename addRoute to setRoutes and take an array of routes
  • Remove the host param from the start function and listen on 0.0.0.0

Version 0.2.1 #

  • Add example of using the library

Version 0.3.0-dev.1 #

  • Clean up example from README in favor of examples/main.dart
  • Change setRoutes to a setter named routes

Version 0.3.0-dev.2 #

  • Remove return type from routes setter

Version 0.3.0-dev.3 #

  • Remove return type from routes setter

Version 0.3.0-dev.4 #

  • Remove return type from routes setter

Version 0.3.1 #

  • Small internal change with how utils work

Version 0.3.2 #

  • Simplify the getRouteMethod function

Version 0.3.3 #

  • Update readme with more information
  • Get the example to stop being stupid
  • Move vscode settings into project folder

example/main.dart

import 'dart:io';
import '../lib/oxide.dart';

void main() {
  Oxide server = new Oxide();
  server.routes = [root];
  server.start(3000);
}

@Route("/", Method.GET)
void root(HttpRequest request) {
  request.response.write('hello world!');
  request.response.close();
}

Use this package as a library

1. Depend on it

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


dependencies:
  oxide: ^0.3.3

2. Install it

You can install packages from the command line:

with pub:


$ pub get

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

3. Import it

Now in your Dart code, you can use:


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

We analyzed this package on Jul 11, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.8.4
  • pana: 0.13.15

Analysis suggestions

Package not compatible with SDK flutter

Because it is not compatible with any of the supported runtimes: flutter-native, flutter-web

Package not compatible with runtime flutter-native on Android

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime flutter-native on Linux

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime flutter-native on Windows

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime flutter-native on iOS

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime flutter-native on macOS

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime flutter-web on Web

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime js

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Package not compatible with runtime native-aot

Because:

  • package:oxide/oxide.dart that imports:
  • package:oxide/src/server.dart that imports:
  • package:oxide/src/util.dart that imports:
  • dart:mirrors

Maintenance issues and suggestions

Homepage URL doesn't exist. (-20 points)

At the time of the analysis the homepage field https://github.com/xpyxel/oxide was unreachable.

Issue tracker URL doesn't exist. (-10 points)

At the time of the analysis the issue_tracker field https://github.com/xpyxel/oxide/issues was unreachable.

Repository URL doesn't exist. (-10 points)

At the time of the analysis the repository field https://github.com/xpyxel/oxide was unreachable.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.8.1 <3.0.0