Friday, 3 February 2017

NG2- Disable HTML Element by default, change elable on (click) button

NG2- Disable HTML Element by default, change elable on (click) button
===============================================
@component({
selector : 'app',
tempalte : `<h1 class="disable"> Header Title (click)="popup()" <h1>
<button (click)="enableHeader()"`,
styles : `.disable{
pointer-events: none;
opacity: 0.5;
}`
})

export class EnaleComponet {

enableHeader(){
document.getElementbyTag('h1).removeClass.disable;
}

popup(){
alert(click also enable);
}
}


I have tried with NG2 & jQuery

No comments:

Post a Comment

Micro front end module federation - UI Arch

  module-federation-examples / module-federation-vite-react                                                          https://github.com/modu...