Skip to content

Instantly share code, notes, and snippets.

View GitHubStuff's full-sized avatar

Steven GitHubStuff

  • LTMM
  • 17:04 (UTC -12:00)
View GitHub Profile
@GitHubStuff
GitHubStuff / README_template.md
Created April 20, 2024 02:10
README.md template

Title

Brief tag line/description

Features

  • Feature
  • Feature

Getting Started

@GitHubStuff
GitHubStuff / SpreadOperator.dart
Created August 28, 2020 21:54
Append List of widgets using IF/Spread operator
Column(
children: [
_buildTitle(),
if (showButtons) ..._buildButtons(),
],
)
List<Widget> _buildButtons() {
// ...
}
@GitHubStuff
GitHubStuff / app_exception.dart
Last active November 8, 2020 16:59
Extend Exception for custom error messages
// Create Exception classes by extending this class.
/// - Example:
/*
class UnknownThemeMode extends AppException {
UnknownThemeMode([String message, int code]) : super(message, 'Missing Context', code);
}
*/
class AppException implements Exception {
final message;
@GitHubStuff
GitHubStuff / History|-1177b0f|entries.json
Last active April 4, 2023 14:35
Flutter widget with pulse animation
{"version":1,"resource":"file:///Users/stevensmith/Flutter/blueprint-flutter/lib/services/service_type/asset_service_ext.dart","entries":[{"id":"mXX9.dart","timestamp":1680147907030},{"id":"hZTO.dart","timestamp":1680183473693},{"id":"GMx7.dart","timestamp":1680183484155},{"id":"WDII.dart","timestamp":1680183499731},{"id":"dhMh.dart","timestamp":1680183517745},{"id":"J6o7.dart","timestamp":1680225547532},{"id":"zeuF.dart","timestamp":1680226872153},{"id":"MTju.dart","timestamp":1680226907305},{"id":"koKW.dart","source":"undoRedo.source","timestamp":1680226972943},{"id":"BZZg.dart","timestamp":1680227281939},{"id":"H63C.dart","timestamp":1680227311849},{"id":"ClXZ.dart","timestamp":1680227322322},{"id":"9g7k.dart","timestamp":1680227381289},{"id":"rzWR.dart","timestamp":1680227423305},{"id":"76ID.dart","timestamp":1680227436273},{"id":"4UoE.dart","timestamp":1680227475595},{"id":"tCO6.dart","timestamp":1680227562413},{"id":"qEDO.dart","timestamp":1680227582372},{"id":"4MBV.dart","timestamp":1680227595072},{"id
@GitHubStuff
GitHubStuff / rotating_animation_widget.dart
Last active August 24, 2021 15:36
Flutter rotating widget
/// Continuous rotattion of a widget
/// [widget] - Widget to rotate {required}
/// [duration] - Duration of the rotation (default [Duration(seconds:15)])
import 'package:flutter/material.dart';
class RotatingAnimationWidget extends StatefulWidget {
final Widget rotatingWidget;
final Duration duration;
const RotatingAnimationWidget(this.rotatingWidget, {this.duration}) : assert(rotatingWidget != null);
_RotatingAnimationWidget createState() => _RotatingAnimationWidget();