Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit ea161bb

Browse files
Create documentation for getJsonAsString function
1 parent 7e3242b commit ea161bb

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

‎example/pubspec.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ packages:
6666
path: ".."
6767
relative: true
6868
source: path
69-
version: "0.0.1"
69+
version: "1.0.0"
7070
matcher:
7171
dependency: transitive
7272
description:

‎lib/jsonloader.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ library jsonloader;
33
import 'package:flutter/services.dart';
44

55
class JSONLoader {
6+
/// Retrieve a string from the JSON file.
7+
///
8+
/// Throws an exception if the file is not found.
69
Future<String> getJsonAsString(String filename) async {
710
var jsonString = rootBundle.loadString(filename);
811
return jsonString;

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /