Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add @woocommerce/price-format dependency #28

Open
1 of 2 tasks
nielslange opened this issue Oct 21, 2021 · 0 comments · May be fixed by #29
Open
1 of 2 tasks

Add @woocommerce/price-format dependency #28

nielslange opened this issue Oct 21, 2021 · 0 comments · May be fixed by #29
Labels
type: enhancement The issue is a request for an enhancement.
Milestone

Comments

@nielslange
Copy link
Member

nielslange commented Oct 21, 2021

Currently, the extension is getting the price format directly from the cart prop. To prevent reinventing the wheel, the price should be formatted using the @woocommerce/price-format dependency.

See also #27 (comment) and p1634901323077500/1634868391.069600-slack-C8X6Q7XQU.

  • Add helper functions getCurrencyFromPriceResponse() and formatPrice().
  • Create mock file to load default values in the editor.
@nielslange nielslange added the type: enhancement The issue is a request for an enhancement. label Oct 21, 2021
@nielslange nielslange changed the title Implement @woocommerce/price-format dependency Add @woocommerce/price-format dependency Nov 25, 2021
@nielslange nielslange added this to the i1 milestone Jan 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement The issue is a request for an enhancement.
Projects
None yet
1 participant