Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import 'package:flutter/material.dart';
- import 'package:flutter_bloc/flutter_bloc.dart';
- import 'package:url_launcher/url_launcher.dart';
- import 'package:common_github_search/common_github_search.dart';
- class SearchForm extends StatefulWidget {
- final GithubRepository githubRepository;
- const SearchForm({
- Key key,
- @required this.githubRepository,
- }) : super(key: key);
- @override
- _SearchFormState createState() => _SearchFormState();
- }
- class _SearchFormState extends State<SearchForm> {
- GithubSearchBloc _githubSearchBloc;
- @override
- void initState() {
- _githubSearchBloc = GithubSearchBloc(
- githubRepository: widget.githubRepository,
- );
- super.initState();
- }
- @override
- void dispose() {
- _githubSearchBloc.dispose();
- super.dispose();
- }
- @override
- Widget build(BuildContext context) {
- return Column(
- children: <Widget>[
- _SearchBar(githubSearchBloc: _githubSearchBloc),
- _SearchBody(githubSearchBloc: _githubSearchBloc)
- ],
- );
- }
- }
Add Comment
Please, Sign In to add comment