Sebastian Rindom 360c71e39a fix: improve error message on incorrect service export (#6240)
**What**
- Provide a more helpful error message if a user adds a file in `src/services` that doesn't export a service class.

**Why**
If you forget to `export default MyClass` in a custom service you can end up with this error:
![CleanShot 2024-01-27 at 6  24 19](https://github.com/medusajs/medusa/assets/7554214/d3700487-33e0-4629-b2c4-a2a37cb86b3e)

It's almost impossible to know how to recover from this which can be an issue for new users. The new error message informs the user that there is a missing class export and shows which file the error is related to.
2024-01-27 23:28:11 +00:00
2023-09-21 20:57:15 +03:00
2024-01-17 11:03:16 +01:00
2023-07-16 21:00:18 +02:00
2023-11-02 10:31:45 +00:00
2024-01-25 16:27:55 +01:00

Medusa logo

Medusa

Documentation | Website

Building blocks for digital commerce

Medusa is released under the MIT license. PRs welcome!

Follow @medusajs Discord Chat

Getting Started

Visit the Quickstart Guide to set up a server.

Visit the Docs to learn more about our system requirements.

What is Medusa

Medusa is a set of commerce modules and tools that allow you to build rich, reliable, and performant commerce applications without reinventing core commerce logic. The modules can be customized and used to build advanced ecommerce stores, marketplaces, or any product that needs foundational commerce primitives. All modules are open-source and freely available on npm.

Learn more about Medusas architecture and commerce modules in the Docs.

Roadmap, Upgrades & Plugins

You can view the planned, started and completed features in the Roadmap discussion.

Follow the Upgrade Guides to keep your Medusa project up-to-date.

Check out all available Medusa plugins.

Community & Contributions

The community and core team are available in GitHub Discussions, where you can ask for support, discuss roadmap, and share ideas.

Our Contribution Guide describes how to contribute to the codebase and Docs.

Join our Discord server to meet other community members.

Other channels

License

Licensed under the MIT License.

Description
No description provided
Readme 539 MiB
Languages
TypeScript 84.9%
JavaScript 14.8%
Shell 0.2%