2.5. Re-Use Customizations with Plugins

In the previous chapters, you've followed the brand example to learn important concepts related to:

You've implemented the brands example within a single Medusa application. However, this approach is not scalable. If you want to use the same brands feature in different Medusa applications, you would have to manually copy the code and maintain it across all projects.

Instead, to reuse your customizations across multiple Medusa applications, you can create a plugin. A plugin is an NPM package that encapsulates your customizations and can be installed in any Medusa application. Plugins can include modules, workflows, API routes, Admin Extensions, and more.

Diagram showcasing how the Brand Plugin would add its resources to any application it's installed in

Medusa provides the tooling to create a plugin package, test it in a local Medusa application, and publish it to NPM.

Refer to the Plugins chapter to learn more about plugins and how to create them.

Was this chapter helpful?
Ask Anything
FAQ
What is Medusa?
How can I create a module?
How can I create a data model?
How do I create a workflow?
How can I extend a data model in the Product Module?
Recipes
How do I build a marketplace with Medusa?
How do I build digital products with Medusa?
How do I build subscription-based purchases with Medusa?
What other recipes are available in the Medusa documentation?
Chat is cleared on refresh
Line break