Skip to content

Commit

Permalink
[doc] Add an example.dart file (#64)
Browse files Browse the repository at this point in the history
Pana suggests to add an example.dart file
here: https://pub.dev/packages/yaml#-analysis-tab-

Closes #45
  • Loading branch information
ayan-b committed Feb 24, 2020
1 parent 2cf77f8 commit 305ae2f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions example/example.dart
@@ -0,0 +1,10 @@
// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

import 'package:yaml/yaml.dart';

void main() {
var doc = loadYaml("YAML: YAML Ain't Markup Language");
print(doc['YAML']);
}

0 comments on commit 305ae2f

Please sign in to comment.