-
Notifications
You must be signed in to change notification settings - Fork 0
Feature/brpa 352 sort by expression #5
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
Conversation
|
Hi! I'm VTEX IO CI/CD Bot and I'll be helping you to publish your app! 🤖 Please select which version do you want to release:
And then you just need to merge your PR when you are ready! There is no need to create a release commit/tag.
|
|
Beep boop 🤖 I noticed you didn't make any changes at the
In order to keep track, I'll create an issue if you decide now is not a good time
|
|
react/utils/sortSellers.ts
Outdated
| ) | ||
|
|
||
| const parser = new Parser() | ||
| const expr = parser.parse(expression) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does the parse function do if the expression is invalid? (very interesting solution btw; sorting sellers by a custom expression seems to be a very customizable/powerful approach 😄)
Oh, and by invalid, I mean a non-empty but incorrect expression.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question! Apparently the application breaks with a invalid expression 😆😢
I will think about a solution for this problem 👨🦯
ConradoClark
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
Beep boop 🤖 That's ok, I created an issue for this so we don't forget |
What problem is this solving?
Added a new option to you make a math expression to sort sellers on Buybox Context. You can use this document to create expressions with seller variables.
Now it's possible use the productPrice and shippingPrice seller variables to create a expression to sort sellers.
We are working to add more variables in the next implementations. This is an initial implementation to test the solution.
How to test it?
Workspace
You can access Site Editor and create your expression like image bellow:
How does this PR make you feel? 🔗