Skip to content

Instantly share code, notes, and snippets.

View harshapulikollu's full-sized avatar
🏠
Working from home

Harsha Pulikollu harshapulikollu

🏠
Working from home
View GitHub Profile
@harshapulikollu
harshapulikollu / rich_text_view.dart
Created June 30, 2019 05:29 — forked from putraxor/rich_text_view.dart
Flutter rich text view with clickable hyperlink
import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:url_launcher/url_launcher.dart' as launcher;
///TODO: check performance impact bro !!!
class LinkTextSpan extends TextSpan {
LinkTextSpan({TextStyle style, String url, String text})
: super(
style: style,
import 'package:flutter/material.dart';
void main() => runApp(new MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return new MaterialApp(
title: 'Flutter Demo',
theme: new ThemeData(
@harshapulikollu
harshapulikollu / main.dart
Created January 18, 2019 04:59 — forked from hillelcoren/main.dart
Enable/disable dark mode with Redux
import 'package:flutter/material.dart';
import 'package:flutter_redux/flutter_redux.dart';
import 'package:redux/redux.dart';
void main() {
final store =
Store<AppState>(reducer, initialState: AppState(enableDarkMode: false));
runApp(MyApp(store: store));
}
@harshapulikollu
harshapulikollu / flutter_spanablegrid.dart
Created January 17, 2019 06:03 — forked from aloisdeniel/flutter_spanablegrid.dart
Custom GridView with various cell sizes in Flutter
import 'dart:math' as math;
import 'package:flutter/material.dart';
import 'package:flutter/src/rendering/sliver.dart';
import 'package:flutter/src/rendering/sliver_grid.dart';
class _CoordinateOffset {
final double main, cross;
_CoordinateOffset(this.main, this.cross);
}