9

Using and Creating Adapters

After developing for several years, you may have a set of common utility functions, a collection of other frameworks, and a library of your own scripts. Maintaining all of these moving parts may become too entropic for an enterprise project or a fleet of microservices. We can restructure our common code into a more generic interface, or pattern, and reclassify those scripts as an “adapter” (also known as a “plugin”).

Using adapters can save us development time, prevent us from repeating ourselves, and help centralize collaboration by maintaining its code base. A few examples of an adapter would be transforming text into a specific character ruleset, scaffolding a sidecar project such as an administrative dashboard, ...

Get Supercharging Node.js Applications with Sequelize now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.