"Avoid using magic numbers or hard-coded values. Instead, use constants or variables to improve code readability and maintainability."
Description
This PR addresses the issue of using hard-coded values and magic numbers in the codebase. It introduces constants and variables to replace these hard-coded values, improving code readability and maintainability. The changes are made in two files: "interface/src/components/backgroundSelector/DownloadProgressCircle.tsx" and "src/background.js".
Summary of Changes
In "DownloadProgressCircle.tsx":
Introduced a constant FULL_WIDTH_CLASS to replace the hard-coded class name "w-full".
Replaced the hard-coded class name "w-full" in the svg element with the new constant.
In "background.js":
Introduced constants for the hard-coded values "MyDatabase", "backgrounds", "customBackground", and "readwrite".
Replaced the hard-coded values with the new constants throughout the file.
These changes improve code maintainability and make it easier to update or modify these values in the future.
PR Feedback: 👎
I created this PR to address this rule:
"Avoid using magic numbers or hard-coded values. Instead, use constants or variables to improve code readability and maintainability."
Description
This PR addresses the issue of using hard-coded values and magic numbers in the codebase. It introduces constants and variables to replace these hard-coded values, improving code readability and maintainability. The changes are made in two files: "interface/src/components/backgroundSelector/DownloadProgressCircle.tsx" and "src/background.js".
Summary of Changes
In "DownloadProgressCircle.tsx":
FULL_WIDTH_CLASS
to replace the hard-coded class name "w-full".In "background.js":
These changes improve code maintainability and make it easier to update or modify these values in the future.