A directive returns an object. Javascript code is put inside a link, compile or controller function.
https://docs.angularjs.org/guide/directive
Put your console.log in the appropriate place and it will run. (EDIT: I'm surprised the code is even ran in the middle of the directive... use link instead)
You forgot to register your module first.
(function () {
'use strict';
angular.module('WizmoApp', []);
angular
.module('WizmoApp')
.directive('validNumber', function () {
console.log("foo");
return {
}
});
})();
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.23/angular.min.js"></script>
<div ng-app="WizmoApp">
<input type="text" class="form-control" name="Value" ng-model="listingVm.form.Value" required valid-number>
</div>