comparison src/index.html @ 18:881840185730

minor
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 15 Sep 2024 07:41:37 -0600
parents 1980e2c32ad6
children dac260018e2e
comparison
equal deleted inserted replaced
17:ab28b0591003 18:881840185730
52 52
53 <p>Most drag-and-drop tools drag the original by setting <b>position</b> to <b>relative</b> and moving it by setting <b>left</b> and <b>top</b>. But this breaks if the DOM is changed. So instead I clone the original and set <b>position</b> of the clone to <b>fixed</b>. This way, changing the DOM doesn't affect the location of what is being dragged.</p> 53 <p>Most drag-and-drop tools drag the original by setting <b>position</b> to <b>relative</b> and moving it by setting <b>left</b> and <b>top</b>. But this breaks if the DOM is changed. So instead I clone the original and set <b>position</b> of the clone to <b>fixed</b>. This way, changing the DOM doesn't affect the location of what is being dragged.</p>
54 54
55 <p>This library is fairly trivial which makes it a good example of <a href="http://www.reactionary.software/">reactionary software</a>. And it is purely JavaScript which everyone knows. Just compare the depraved alternatives listed to my code. My code is much simpler and is fully functional and robust. All of the modern alternatives are overcomplicated and fragile garbage. All modern code is like this, all just horrible garbage.</p> 55 <p>This library is fairly trivial which makes it a good example of <a href="http://www.reactionary.software/">reactionary software</a>. And it is purely JavaScript which everyone knows. Just compare the depraved alternatives listed to my code. My code is much simpler and is fully functional and robust. All of the modern alternatives are overcomplicated and fragile garbage. All modern code is like this, all just horrible garbage.</p>
56 56
57 <p>Here is <a href="https://hg.reactionary.software/repo/dad/">the source</a> of this website. And here is <a href="http://mikraite.arkian.net/JavaScript-Drag-and-Drop-tp3229.html">a discussion thread</a> if you want to comment.</p> 57 <p>Here is <a href="https://hg.reactionary.software/repo/dad/">the source</a> of this website. And here is <a href="https://mikraite.arkian.net/JavaScript-Drag-and-Drop-tp3229.html">a discussion thread</a> if you want to comment.</p>
58 </body> 58 </body>
59 </html> 59 </html>