I am currently working with Angular 4 and I am attempting to switch between contenteditable="true" and contenteditable="false"
Here is what I have so far:
<h1 (dblclick)="edit($event)" contentEditable="true">Double-click Here to edit</h1>
Alternatively, I could use a checkbox for toggling the edit mode if that would be simpler?
<input type="checkbox" name="" value="" (onchange)="edit($event)">Toggle Edit mode
and in the corresponding TypeScript file:
edit(event) {
// additional code required here
}