Open johnpolitowski opened 6 years ago
Actually I figured it out. It can be accessed by innerHTML of target
$scope.$on('script-editor.drop', function (el, target, source, sibling) {
console.log('target', target);
angular.forEach(target[0].classList, function(className){
if(className == 'template'){
//console.log('got one!');
target[0].innerHTML = 'boombap';
}
});
});
I'm trying to insert some dynamic content into to copied elements, such as unique id, and a directive depending on what is dragged. Is that possible?