Add define function, maintain backward compatibility
Accept Closures as attribute factory
Merge pull request #15 from dimrsilva/master

Remove test code from your source