I did this on a textarea. I dump the data into a variable and then use the variable as the data source for this textarea. All the user has to do is click anywhere in the textarea and that copies the contents to the clipboard.
A bit of clever CSS on the textarea can make it look like all other DIVs.
I’ve not been able to get it to work (easily) on a DIV yet.
<textarea id="text2" class="form-control" dmx-on:click="browser1.selectAll();browser1.copy()" value="" dmx-bind:value="inp_driv_rep_status.value.default('No Data!')" placeholder="Please be patient..."></textarea>
Formatter replace in expression [email_list.value.replace(',', '<br>')] doesn't exist for type array
and I’ve tried using .split() since Wappler seems to think I have an array, and that gives a similar message.
So even though email_list feels like a variable which contains plain text, it looks like Wappler considers it to be an array, but I can’t split it like an array…
I think it is one of those things dating back to early terminals, etc. Line feed \n was to move to next line and carriage return \r was to move to the far left.