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

migrated from lineTo() -> addPolygon() #19

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

TamilKannanCV
Copy link

Problem description

We have used lineTo(x, y) to draw the Polygon for our Button (Tile Button, Card). The problem here is the lineTo(x, y) is called multiple times which is not a good approach for drawing a polygon. This leads to a slight drop in performance.

Type of change

✅ Enhancement

Solution Approach

To solve this issue, I've used addPolygon([], true) instead of lineTo(x, y) functions. This is the most efficient approach to solve the problem.

Reference

Reference from ChatGPT
image

About Me

I'm Tamil Kannan, an experienced Flutter developer, open to work at CRED.

Portfolio: https://tamilkannancv.dev
Resume: https://tamilkannancv.dev/resume.pdf
Contact me: [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant