Skip to content

Instantly share code, notes, and snippets.

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

Deshar Sunil deshario

🏠
Working from home
  • bangkok
View GitHub Profile
/* eslint-env serviceworker */
/* eslint-disable no-console */
import localForage from 'localforage'
import { matchPrecache, precacheAndRoute } from 'workbox-precaching'
import { registerRoute, setCatchHandler } from 'workbox-routing'
import { CacheFirst, NetworkFirst } from 'workbox-strategies'
self.addEventListener('install', (event) => {
self.skipWaiting()

Dillinger

The Last Markdown Editor, Ever

N|Solid

Build Status

Dillinger is a cloud-enabled, mobile-ready, offline-storage compatible, AngularJS-powered HTML5 Markdown editor.

@deshario
deshario / keywords.csv
Created September 27, 2023 10:09
Sample keywords csv file
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
Best hotels in new york
Best hotels in tokyo
Bangkok attractions
Rolex
Gaming laptop
Best hiking trails
washing machine amazon
workout routines
Alibaba best product
Trending products in thailand
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import 'dart:io';
import 'package:flutter/foundation.dart';
import 'package:firebase_messaging/firebase_messaging.dart';
import 'package:myapp/model/Message.dart';
class CloudMessaging {
FirebaseMessaging firebaseMessaging;
ValueChanged<Message> onReceived;
@deshario
deshario / order-updater.php
Last active February 19, 2020 09:52
WooCommerce Order Status Updater
<pre style="margin-left:30px; margin-bottom:30px;">
_ _ ___ ___ ____ ___ ____ ___ ____ ____ ___ ____ ____ ____
| | |__] | \ |__| | |___ | \ | | |__/ | \ |___ |__/ [__
|__| | |__/ | | | |___ |__/ |__| | \ |__/ |___ | \ ___]
</pre>
<?php
require_once("../wp-load.php");
$totalOrders = array();
$affectedOrders = array();
@deshario
deshario / QrDialog.dart
Last active July 30, 2024 07:20
Render QrView in Dialog
import 'package:flutter/material.dart';
import 'package:deshario/components/ScannerOverlay.dart';
import 'package:qr_code_scanner/qr_code_scanner.dart';
class QrDialog extends StatefulWidget {
final String dialogTitle;
final ValueChanged<String> onGetResult;
QrDialog({
@deshario
deshario / PListView.dart
Last active March 3, 2020 04:37
ListView with Nested childrens
import 'package:flutter/material.dart';
import 'package:store/model/Entry.dart';
class PListView extends StatelessWidget {
final List<Entry> dataEntry;
final ValueChanged<String> onSelect;
PListView({
Key key,