howler 1.0.2

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • new51

howler.dart

Description

howler.dart is an audio library for the modern web. It defaults to Web Audio API and falls back to HTML5 Audio. This makes working with audio in Dart easy and reliable across all platforms.

Additional information, live demos and a user showcase are available at howlerjs.com.

Usage

A simple usage example:

import 'package:howler/howler.dart';

main() {

    var howl = new Howl(
        src: ['audio/track.mp3','audio/track.wav'], // source in MP3 and WAV fallback
        loop: true,
        volume: 0.60 // Play with 60% of original volume.
    ) ;
    
    howl.play(); // Play sound.
    howl.fade(0.0, 0.60, 10000) ; // Make a fade, from volume 0% to 60% in 10s

}

Features and bugs

Please file feature requests and bugs at the issue tracker.

Author

Graciliano M. Passos: gmpassos@GitHub.

License

MIT license.

Original project in JavaScript

This library was originally written in JavaScript by James Simpson. It was ported to Dart 2 code by Graciliano M. Passos.

You can find the original project at GitHub(howler.js).

Project site: howlerjs.com

1.0.1

  • Added logo images.

1.0.0

example/howler_example.dart

import 'package:howler/howler.dart';

main() {

  var howl = new Howl(
      src: ['audio/track.mp3','audio/track.wav'], // source in MP3 and WAV fallback
      loop: true,
      volume: 0.60 // Play with 60% of original volume.
  ) ;

  howl.play(); // Play sound.
  howl.fade(0.0, 0.60, 10000) ; // Make a fade, from volume 0% to 60% in 10s

}

Use this package as a library

1. Depend on it

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


dependencies:
  howler: ^1.0.2

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:howler/howler.dart';
  
Version Uploaded Documentation Archive
1.0.2 Jan 6, 2019 Go to the documentation of howler 1.0.2 Download howler 1.0.2 archive
1.0.1 Jan 6, 2019 Go to the documentation of howler 1.0.1 Download howler 1.0.1 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
11
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]
51
Learn more about scoring.

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

  • Dart: 2.1.0
  • pana: 0.12.10

Platforms

Detected platforms: web

Primary library: package:howler/howler.dart with components: html.

Health suggestions

Fix lib/src/howler_base.dart. (-1.49 points)

Analysis of lib/src/howler_base.dart reported 3 hints:

line 1653 col 3: This function has a return type of 'double', but doesn't end with a return statement.

line 1741 col 3: This function has a return type of 'double', but doesn't end with a return statement.

line 2020 col 3: This function has a return type of 'Howl', but doesn't end with a return statement.

Format lib/howler.dart.

Run dartfmt to format lib/howler.dart.

Maintenance suggestions

The description is too short. (-20 points)

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
swiss_knife ^2.0.0 2.0.0
Transitive dependencies
intl 0.15.7
path 1.6.2
Dev dependencies
test ^1.5.1