event based rewrite

small core with everything going through events
in that scope 'arguments' is a js object, that i turn into an array