Files
medusa-store/www/apps/docs
Nick Miller e4157875b5 docs(create tax provider): tax line code required (#5540)
While I was developing a custom tax provider, I ran into a pretty frustrating issue related to multiple tax lines and incorrect / unexpected tax total calculations. I outlined the issue in discord, before finding the solution: https://discord.com/channels/876835651130097704/1169705457804398662

After some digging, I found this issue from a while back: https://github.com/medusajs/medusa/pull/1262, where it states there is now a unique constraint on `item_id, code` and `shipping_method_id, code`. But, in the current documentation for creating a custom tax provider, it states these fields as part of the tax line items returned are optional.

If these `code` values are left out, it can cause tax lines to be applied multiple times (as seen here as well: https://github.com/medusajs/medusa/issues/1901)

I'm not entirely sure how this should be phrased in the documentation, so I just wanted to get this up and on your radar for resolution. If it ends up being that `code` truly should not be optional, I suspect some type definitions would need to change as well?
2023-11-06 17:12:56 +00:00
..
2023-09-21 20:57:15 +03:00
2023-09-21 20:57:15 +03:00

Medusa Documentation

The Medusa documentation website is built with Docusaurus v2. You can learn more about contributing here.

Components and Theme

Extended Theme Components

Components that extend themes from Docusaurus or other plugins are placed under src/theme.

Medusa Docs Components

Components created specifically for the Medusa Docs are placed under the src/componenets directory.