Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Jirachai Chansivanon antronic

🏠
Working from home
View GitHub Profile
@antronic
antronic / embedded_countdown.js
Created Mar 31, 2020
Idea for inject embedded countdown DOM element
View embedded_countdown.js
(function() {
const today = new Date()
const _targetTime = prompt('Input your end time', `${today.getMonth() + 1}/${today.getDate()}/${today.getFullYear()} ${today.getHours()}:${today.getMinutes()}:${today.getSeconds()}`)
const targetTime = new Date(_targetTime)
if (isNaN(targetTime)) {
throw new Error('Your time input is invalid date format.')
}
View jsbkk-seek.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Meow~</title>
</head>
<body>
Hello JSBKK
</body>
View req-printer.md

/api/print

Req file - Image File

Res id - Queue ID for reference to print status (IF POSSIBLE, IF CAN'T IT OK NA)


@antronic
antronic / bh_invoice_cal_ex.js
Last active Jul 18, 2019
bh_invoice_cal_ex.js
View bh_invoice_cal_ex.js
data = {
invoices: [
{
chargeDetail: [
{
description: 'ค่ายา',
chargeDetailSubWTF: [
{
cost: 10,
@antronic
antronic / iphone-usb_tethering-to-rpi.md
Last active Oct 4, 2020
iPhone USB Tethering to RPi
View iphone-usb_tethering-to-rpi.md

iPhone Tethering to Raspberry Pi

Instruction

On RPi

  • sudo apt-get install usbmuxd
  • connect iPhone

On iPhone

  • Trust

View DefaultStyle-extends.css
@media (prefers-dark-interface)
{
html {
-apple-color-filter: apple-invert-lightness();
}
a {
-apple-color-filter: none;
color: -webkit-link;
}
img {
@antronic
antronic / page-for-chatbot-test-privacy-policy.txt
Created Feb 14, 2019
Page-for-chatbot-test Privacy Policy
View page-for-chatbot-test-privacy-policy.txt
WE DO NOT STORE ANY DATA OR MESSAGES YOU SEND TO YOUR CONTACTS AND CRM.
View word_analyze_amp.js
function check_word(msg) {
let temp = msg.toLowerCase()
temp = temp.replace(' the', '')
temp = temp.split(' ')
console.log(temp)
let turn = -1
let device = 0
@antronic
antronic / widgetapp.dart
Created May 3, 2018
Create Flutter app with WidgetApp class
View widgetapp.dart
// Special thanks: Hemanth Raj
// Ref: https://stackoverflow.com/questions/48024504/app-navigation-example-using-widgetsapp#answer-48030789
import 'package:flutter/widgets.dart';
void main() => runApp(new MyWidgetsApp());
class MyWidgetsApp extends StatelessWidget {
Route generate(RouteSettings settings){
Route page;
You can’t perform that action at this time.