cleanup & custom directive