dialog_polyfill 0.4.3-1

  • README.md
  • Example
  • Installing
  • Versions
  • 35

dialog_polyfill

Dart package for dialog-polyfill.js.

Usage

<head>
  <script type="text/javascript" src="packages/dialog_polyfill/dialog-polyfill.js"></script>
  <link rel="stylesheet" type="text/css" href="packages/dialog_polyfill/dialog-polyfill.css"/>
</head>

example/main.dart

import 'dart:html';
import 'package:dialog_polyfill/dialog_polyfill.dart';

main() {
  var element = querySelector('dialog');
  var dialog = new Dialog(element);

  querySelector('#show').onClick.listen((_) {
    dialog.show();
  });
  querySelector('#show-modal').onClick.listen((_) {
    dialog.showModal();
  });
  querySelector('#close').onClick.listen((_) {
    dialog.close();
  });
}

1. Depend on it

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


dependencies:
  dialog_polyfill: "^0.4.3-1"

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:dialog_polyfill/dialog_polyfill.dart';
        
Version Uploaded Documentation Archive
0.4.3-1 May 30, 2016 Go to the documentation of dialog_polyfill 0.4.3-1 Download dialog_polyfill 0.4.3-1 archive

Analysis

This feature is new.
We welcome feedback.
More details: scoring.

We analyzed this package, and provided a score, details, and suggestions below.

  • completed on Feb 3, 2018
  • Dart: 2.0.0-dev.20.0
  • pana: 0.10.1

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
0 / 100
Health:
Code health derived from static analysis. [more]
100 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
25 / 100
Overall score:
Weighted score of the above. [more]
35

Platforms

Detected platforms: web

Primary library: package:dialog_polyfill/dialog_polyfill.dart with components: html, js.

Suggestions

  • Maintain CHANGELOG.md.

    Changelog entries help clients to follow the progress in your code.

  • Package is pre-release.

    Pre-release versions should be used with caution, their API may change in breaking ways.

  • The description is too short.

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

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

Dependencies

Package Constraint Resolved Available
Dev dependencies
browser any