<commit_before>A QR code generation library for Dart and Flutter.

[![CI](https://github.com/kevmoo/qr.dart/workflows/ci/badge.svg)](https://github.com/kevmoo/qr.dart/actions?query=workflow%3A%22ci%22)

# Features

- Supports QR code versions 1 - 40
- Error correction / redundancy

# Getting started

To start, import the dependency in your code:

```dart
import 'package:qr/qr.dart';
```

To build your QR code data you should do so as such:

```dart
final qrCode = QrCode(4, QrErrorCorrectLevel.L)
  ..addData('Hello, world in QR form!');
final qrImage = QrImage(qrCode);
```

Now you can use your `qrImage` instance to render a graphical representation of the QR code. A basic implementation would be as such:

```dart
for (var x = 0; x < qrImage.moduleCount; x++) {
  for (var y = 0; y < qrImage.moduleCount; y++) {
    if (qrImage.isDark(y, x)) {
      // render a dark square on the canvas
    }
  }
}
```

See the `example` directory for further details.

# Pre-made UI libraries

The following libraries use qr.dart to generate QR codes for you out of the box:

[QR - Flutter](https://github.com/lukef/qr.flutter) - A Flutter Widget to render QR codes

[QR - AngularDart](https://github.com/gazialankus/qr.angulardart) - An AngularDart component to render QR codes

# Demo

A working demo can be found here: [https://kevmoo.github.io/qr.dart/](https://kevmoo.github.io/qr.dart/)
<commit_msg>readme cleanup<commit_after>A QR code generation library for Dart and Flutter.

[![CI](https://github.com/kevmoo/qr.dart/workflows/ci/badge.svg)](https://github.com/kevmoo/qr.dart/actions?query=workflow%3A%22ci%22)

# Features

- Supports QR code versions 1 - 40
- Error correction / redundancy

# Getting started

To start, import the dependency in your code:

```dart
import 'package:qr/qr.dart';
```

To build your QR code data you should do so as such:

```dart
final qrCode = QrCode(4, QrErrorCorrectLevel.L)
  ..addData('Hello, world in QR form!');
final qrImage = QrImage(qrCode);
```

Now you can use your `qrImage` instance to render a graphical representation of
the QR code. A basic implementation would be as such:

```dart
for (var x = 0; x < qrImage.moduleCount; x++) {
  for (var y = 0; y < qrImage.moduleCount; y++) {
    if (qrImage.isDark(y, x)) {
      // render a dark square on the canvas
    }
  }
}
```

See the `example` directory for further details.

# Pre-made UI libraries

The following libraries use qr.dart to generate QR codes for you out of the box:

[qr_flutter](https://pub.dev/packages/qr_flutter) - A Flutter Widget to render
QR codes

[barcode](https://pub.dev/packages/barcode) - A package that supports many types
of scannable codes, include QR.

# Demo

A working demo can be found here:
[kevmoo.github.io/qr.dart](https://kevmoo.github.io/qr.dart/)

{'fraction_non_alphanumeric': 0.12611967036904334, 'fraction_numerical': 0.007882479398065209, 'mean_word_length': 3.8641114982578397, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 11, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2508627', 'n_tokens_mistral': 1033, 'n_tokens_neox': 953, 'n_words': 319}