Skip to content

Instantly share code, notes, and snippets.

View nektobit's full-sized avatar
🎯
Focusing

Iakimchuk Dmitrii nektobit

🎯
Focusing
View GitHub Profile
@darrenmothersele
darrenmothersele / drop-zone-directive.ts
Last active July 12, 2024 13:05
Angular Drag and Drop File Directive
import { Directive, EventEmitter, HostBinding, HostListener, Input, Output } from '@angular/core';
// Angular Drag and Drop File
//
// Add this directive to an element to turn it into a dropzone
// for drag and drop of files.
// Example:
//
// <div (appDropZone)="onDrop($event)"></div>
//