added prop/attrib distinction, rewrite to half size
cleanup