Skip to content

Instantly share code, notes, and snippets.

@felangel
Created January 21, 2019 20:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save felangel/a507da75dcfff25bc90eb48ba03308e1 to your computer and use it in GitHub Desktop.
Save felangel/a507da75dcfff25bc90eb48ba03308e1 to your computer and use it in GitHub Desktop.
[github_search] Search Result Item Model
import 'package:common_github_search/common_github_search.dart';
class SearchResultItem {
final String fullName;
final String htmlUrl;
final GithubUser owner;
const SearchResultItem({this.fullName, this.htmlUrl, this.owner});
static SearchResultItem fromJson(dynamic json) {
return SearchResultItem(
fullName: json['full_name'] as String,
htmlUrl: json['html_url'] as String,
owner: GithubUser.fromJson(json['owner']),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment