Directives now must be registered by name (string) and function