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

Bug: Hardcoded Height and Width Used Throughout the Codebase #616

Closed
ganidande905 opened this issue Dec 11, 2024 · 1 comment · Fixed by #619
Closed

Bug: Hardcoded Height and Width Used Throughout the Codebase #616

ganidande905 opened this issue Dec 11, 2024 · 1 comment · Fixed by #619
Assignees
Labels
bug Something isn't working

Comments

@ganidande905
Copy link
Contributor

ganidande905 commented Dec 11, 2024

Description:

I have noticed that the height and width values are hardcoded at various places in the codebase, even though Get.height and Get.width (or similar responsive utilities) are available for dynamic dimensioning.

Disadvantages of Hardcoding Height and Width:

1.Lack of Responsiveness:

  • Hardcoded dimensions do not adapt to different screen sizes or orientations, leading to poor user experience on devices with varying resolutions.

2.Inconsistent UI:

  • Hardcoded values may cause inconsistencies across different screen sizes.

3.Difficulty in Maintenance:

  • Updating UI for new screen sizes or layouts requires manually changing hardcoded values throughout the code, which is error-prone and time-consuming.

4.Inflexibility for Dynamic Content:

  • Hardcoded dimensions can break layouts when the app content changes dynamically (e.g., localization, font scaling, or varying data).

5.Reduces Code Reusability:

  • Widgets or components with hardcoded dimensions are less reusable, limiting modularity and scalability.

6.Inefficient Testing:

  • Testing becomes cumbersome as hardcoded values need validation for multiple screen configurations and edge cases.

Suggested Solution:

  • Utilize Flutter widgets like LayoutBuilder or MediaQuery in cases where Get.height and Get.width are not directly applicable.

By addressing this issue, we can enhance the responsiveness, maintainability, and overall quality of the app's user interface

Solving this issue could also solve the issue #611

@ganidande905 ganidande905 added the bug Something isn't working label Dec 11, 2024
@ganidande905
Copy link
Contributor Author

ganidande905 commented Dec 11, 2024

hey @AryanSarafDev could you just go through this issue and assign this to me and also the issue which is co-related to this issue #611

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant