<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/sources/stackab/best-of/2022" -->

---
title: Best Stack Abuse posts of 2022 | daily.dev
description: The most upvoted Stack Abuse posts of 2022, curated by the daily.dev community.
canonical: https://daily.dev/sources/stackab/best-of/2022
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:url: https://daily.dev/sources/stackab/best-of/2022
og:type: website
og:site_name: daily.dev
og:title: Best Stack Abuse posts of 2022 | daily.dev
og:description: The most upvoted Stack Abuse posts of 2022, curated by the daily.dev community.
og:image: https://media.daily.dev/image/upload/s--VAY5ToZt--/f_auto/v1724209435/public/daily.dev%20-%20open%20graph
---

# Best of Stack Abuse — 2022

1. 1  
[](/posts/testing-node-js-code-with-mocha-and-chai-dau8dm6vi "Testing Node.js Code with Mocha and Chai")  
[![stackab's profile](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/665f1794129347ddaf1340a2cce028d1)](/sources/[source]/best-of/[year])  
9m read time • Dec 01, 2022  
### Testing Node.js Code with Mocha and Chai  
The basic premise of test-driven development (TDD) is writing your tests even before you start coding. To make this whole process a lot easier, you can resort to easy-to-use and powerful testing and assertion frameworks, such as Mocha and Chai. Chai is an assertion library that provides both the BDD and TDD.

+3  
![Post Cover image](https://media.daily.dev/image/upload/t_mobile_feed/v1/posts/8aba030deea5d6518dafba4e24ba3b62)  
23  
4
2. 2  
[](/posts/guide-to-lazy-loading-with-react-1sg2kvjyl "Guide to Lazy Loading With React")  
[![stackab's profile](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/665f1794129347ddaf1340a2cce028d1)](/sources/[source]/best-of/[year])  
5m read time • Jun 27, 2022  
### Guide to Lazy Loading With React  
Lazy loading allows us to load specific components only when they are needed. We can avoid pre-loading content while it's still out of view, and focus all of the resources on the content that is in the view. Using dynamic imports alongside the React.lazy() will enable us to import a component just before it renders on a screen.

+1  
12  
1
3. 3  
[](/posts/drag-and-drop-in-vanilla-javascript-6yndh12sy "Drag and Drop in Vanilla JavaScript")  
[![stackab's profile](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/665f1794129347ddaf1340a2cce028d1)](/sources/[source]/best-of/[year])  
9m read time • Mar 16, 2022  
### Drag and Drop in Vanilla JavaScript  
The act of picking an item or chunk of text, moving it, and then placing it in another location is known as drag-and-drop functionality. With a mouse, the user may pick draggable items, drag them to a droppable element, then drop them by releasing the mouse button. To implement drag and drop functionality in conventional HTML4, developers had to utilize difficult JavaScript programming or other JavaScript frameworks like jQuery. HTML 5 introduced a Drag and Drop (DnD) API that delivers native DnD support to the browser.

+1  
11

[See all Stack Abuse archives](/sources/stackab/best-of)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@graph":[{"@type":"CollectionPage","@id":"https://daily.dev/sources/stackab/best-of/2022#page","url":"https://daily.dev/sources/stackab/best-of/2022","name":"Best Stack Abuse Posts of 2022","description":"The most upvoted Stack Abuse posts of 2022, curated by the daily.dev community.","isPartOf":{"@type":"WebSite","url":"https://daily.dev"}},{"@type":"ItemList","@id":"https://daily.dev/sources/stackab/best-of/2022#items","numberOfItems":3,"itemListElement":[{"@type":"ListItem","position":1,"url":"https://daily.dev/posts/testing-node-js-code-with-mocha-and-chai-dau8dm6vi","name":"Testing Node.js Code with Mocha and Chai"},{"@type":"ListItem","position":2,"url":"https://daily.dev/posts/guide-to-lazy-loading-with-react-1sg2kvjyl","name":"Guide to Lazy Loading With React"},{"@type":"ListItem","position":3,"url":"https://daily.dev/posts/drag-and-drop-in-vanilla-javascript-6yndh12sy","name":"Drag and Drop in Vanilla JavaScript"}]},{"@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Sources","item":"https://daily.dev/sources"},{"@type":"ListItem","position":3,"name":"Stack Abuse","item":"https://daily.dev/sources/stackab"},{"@type":"ListItem","position":4,"name":"Best of","item":"https://daily.dev/sources/stackab/best-of"},{"@type":"ListItem","position":5,"name":"2022"}]}]}
```

