Disclaimer: I predominantly work with React, so the opinions in this article are mainly drawn from that experience. It may or may not be less relevant in other contexts.
With ES modules, there are 2 ways to export a module: default exports, and named exports.
As a quick reminder, a default export looks something like this:
export default () =>…