ng-filedrop
v1.0.0
Published
file drop directive for angular
Downloads
1
Readme
ng-fileDrop
file drop directive for angular
使用
<script src="./angular.min.js"></script>
<script src="../dist/ng-fileDrop.min.js"></script>
<script>
window.ondragover = function(e) {
e.preventDefault();
return false;
};
window.ondrop = function(e) {
e.preventDefault();
return false;
};
angular.module('app', ['ng-fileDrop']).controller('AppCtrl', function($scope, $log) {
$scope.ondrop = function(files) {
$log.debug('ondrop:', files);
};
});
</script>