Skip to content

Instantly share code, notes, and snippets.

View RohmanBenyRiyanto's full-sized avatar
🤚
Mobile Developer

Rohman Beny Riyanto RohmanBenyRiyanto

🤚
Mobile Developer
View GitHub Profile
@RohmanBenyRiyanto
RohmanBenyRiyanto / CostumStateMixin.dart
Last active March 1, 2023 12:14
Costum State Mixin Flutter
mixin CustomStateMixin<T> on State<T> {
var _state = CustomState.idle;
var _message = '';
void setIdleState() {
setState(() {
_state = CustomState.idle;
});
}
@RohmanBenyRiyanto
RohmanBenyRiyanto / Flutter Custom Tickets using Clip Path.dart
Last active February 24, 2025 08:47
Create a custom ticket card display in flutter
class CustomTicket extends CustomClipper<Path> {
@override
Path getClip(Size size) {
final path = Path();
//Radius
path.addRRect(
RRect.fromRectAndRadius(
Rect.fromLTWH(0, 0, size.width, size.height),
const Radius.circular(8),
),
@RohmanBenyRiyanto
RohmanBenyRiyanto / ResponseFormatter.php
Created December 13, 2021 18:23 — forked from galpratama/ResponseFormatter.php
API Response Formatter
<?php
namespace App\Http\Controllers\API;
class ResponseFormatter
{
protected static $response = [
'meta' => [
'code' => 200,
'status' => 'success',