Skip to content

Instantly share code, notes, and snippets.

@uasi
uasi / MyWebViewController.m
Last active Jan 27, 2016
WebView からサンドボックス内のローカルファイルを読み込もうとするリクエストを書き換えるやつ
View MyWebViewController.m
@interface MyWebViewController : NSObject
@property IBOutlet WebView *webView; // nib 内の WebView に接続済みということで
@end
@implementation MyWebViewController <WebResourceLoadDelegate>
- (void)awakeFromNib {
// WebView にデリゲートを接続
self.webView.resourceLoadDelegate = self;
}
@uasi
uasi / macro_expansion_steps.exs
Last active Aug 29, 2015
Elixir で Plug.Builder 相当の DSL を再実装してマクロの展開順を追ってみた
View macro_expansion_steps.exs
### start from here ###
defmodule MyApp do
use MyPlugBuilder
plug :hello
plug :world, good: :morning
end
### expand `use MyPluginBuilder` macro ↓ ###
@uasi
uasi / file0.txt
Last active Aug 29, 2015
ブランチの最終更新日時を一覧にする git branch-activity 書いた ref: http://qiita.com/uasi/items/430f9403ac9b437c0499
View file0.txt
usage: git branch-activity [-r | -a] [-R] [--no-color]
@uasi
uasi / ghq-foreach.sh
Created Apr 14, 2015
ghq で管理している各リポジトリでコマンドを実行する ghq-foreach 書いた ref: http://qiita.com/uasi/items/610ef5745fc35745fd54
View ghq-foreach.sh
#!/bin/bash
#
# ghq-foreach - executes git subcmd or shell cmd for each repo managed by ghq
#
EXEC=
QUIET=
say() {
@uasi
uasi / set_lang_locale.bash
Last active Aug 29, 2015
Language and Locale Settings
View set_lang_locale.bash
defaults write com.adobe.Flash AppleLanguages -array ja
defaults write com.adobe.Flash AppleLocale ja_JP
@uasi
uasi / defer.rs
Last active May 12, 2017
"defer" in Rust (virtually useless)
View defer.rs
// rustc 1.0.0-nightly (44a287e6e 2015-01-08 17:03:40 -0800)
#![feature(unboxed_closures)]
#![feature(unsafe_destructor)]
macro_rules! defer {
($($body:stmt);* ;) => {
let __deferred = Deferred::new(|| { $($body);* ; });
}
}
View html51.md

1.4歴史 第5段落

2003年に、ウェブフォームの次世代として位置づけられた技術であるXFormsの公表は、HTMLの代替を見つけることよりも、進化するHTML自身に再び関心を巻き起こした。 この関心は、ウェブ技術が(RSSや後のAtomのような)新しい技術に限られていたXMLの展開というよりむしろ、(HTMLのような)実際に展開された技術の置換から生まれた。

原文

In 2003, the publication of XForms, a technology which was positioned as the next generation of Web forms, sparked a renewed interest in evolving HTML itself, rather than finding replacements for it. This interest was borne from the realization that XML's deployment as a Web technology was limited to entirely new technologies (like RSS and later Atom), rather than as a replacement for existing deployed technologies (like HTML).

私案

View git-prune-branches.sh
#!/bin/sh
#
# git-prune-branches - prune merged branches
#
# Configurations:
# .git/protected-branches - one-line regex matching the names of the branches to be protected.
#
if [ "`git branch | grep '^\*'`" != "* master" ]; then
View EXNOnDealloc.h
//
// EXNOnDealloc.h
//
// Copyright (c) 2014 uasi. All rights reserved.
//
#import <libextobjc/metamacros.h>
#define onDeallocOfObject(object) \
autoreleasepool {} \
@uasi
uasi / CDEvents+RACExtensions.h
Created Oct 18, 2014
CDEvents+RACExtensions
View CDEvents+RACExtensions.h
//
// CDEvents+RACExtensions.h
// Kobito
//
// Copyright (c) 2014 Increments Inc. All rights reserved.
//
#import <CDEvents/CDEvents.h>
@class RACSignal;
You can’t perform that action at this time.