Réponse

var app = angular.module("myApp", []);
app.directive("newTestDirective", function() { };

Explication

In addition to all the built-in AngularJS directives, you can create your own directives.
Exemple : <body ng-app="myApp">
<w3-test-directive></w3-test-directive>

<script>
var app = angular.module("myApp", []);
app.directive("w3TestDirective", function() {
return {
template : "<h1>Made by a directive!</h1>"
};
});
</script>

</body>

Question

Create new directive call 'newTestDirective' by using the .directive function for 'myApp'.

Thématique