Skip to content

Instantly share code, notes, and snippets.

View hironytic's full-sized avatar

Hironori Ichimiya hironytic

  • Tokushima, Japan
  • 11:09 (UTC +09:00)
  • X @hironytic
View GitHub Profile
#import <UIKit/UIKit.h>
#import <XCTest/XCTest.h>
@interface ObjCExp1Tests : XCTestCase
@end
@implementation ObjCExp1Tests
- (void)setUp {
@hironytic
hironytic / 00_subscribeOn_observeOn.js
Last active December 13, 2015 15:14
subscribeOn() v.s. observeOn()
import Rx from "rx-lite-extras";
const observable1 = Rx.Observable.create(observer => {
console.log("[A] call onNext(1)");
observer.onNext(1);
console.log("[A] called onNext(1)");
console.log("[B] call onNext(2)");
observer.onNext(2);
console.log("[B] called onNext(2)");
@hironytic
hironytic / dict.swift
Created August 23, 2017 05:53
dict.swift
var d = [String: String?]()
var s: String? = nil
d["key"] = s // nil入る
print(d)
d["key"] = nil // 削除
print(d)
@hironytic
hironytic / iosdc2018_hiron_links.md
Last active September 9, 2018 06:27
iOSDC Japan 2018のLT「全部iOSにしゃべらせちゃえ!」のリンク集
@hironytic
hironytic / presentations.md
Last active January 19, 2025 10:14
ひろんの登壇資料
@hironytic
hironytic / iosdc2018_hiron_scenario.json
Created September 2, 2018 14:06
iOSDC Japan 2018のLT「全部iOSにしゃべらせちゃえ!」に使ったシナリオ。
{
"language": "ja-JP",
"rate": 0.5,
"pitch": 1.0,
"volume": 0.8,
"postDelay": 0.5,
"presets" : [
{
"text" : "準備できましたぁ"
},
//
// CallStackReporter.swift
// DramaticCrash
//
// Copyright (c) 2018 Hironori Ichimiya <hiron@hironytic.com>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
import 'package:flutter/material.dart';
import 'package:my_app/BlocProvider.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
// This widget is the root of your application.
@hironytic
hironytic / attributes.swift
Created March 24, 2019 13:15
Attributes with namespace (Foundation on macOS)
import Cocoa
let uriNs1 = "http://example.com/ns1"
let uriNs2 = "http://example.com/ns2"
let root = XMLNode.element(withName: "root") as! XMLElement
root.addNamespace(XMLNode.namespace(withName: "ns1", stringValue: uriNs1) as! XMLNode)
let element = XMLNode.element(withName: "element") as! XMLElement
element.addNamespace(XMLNode.namespace(withName: "ns2", stringValue: uriNs2) as! XMLNode)