Open
Description
Requirement
Using absolute imports improves:
- Code Readability: No more long and complex relative paths.
- Maintainability: Refactoring becomes easier as file paths are consistent.
- Scalability: Simplifies project navigation in large codebases.
import Button from '../../components/Button';
import Header from '../../../shared/Header';
Absolute imports
import Button from 'components/Button';
import Header from 'shared/Header';
### Problem
The problem with relative imports in React projects arises as the codebase grows larger and more complex.
Activity
yurishkuro commentedon Jan 7, 2025
I agree in principle, but I don't think it's a task we should be pursuing for its own sake, since it's going to take a lot of effort which could instead go into solving more pressing issues like the stale dependencies.
yashpandey06 commentedon Jan 7, 2025
@yurishkuro Yeah , I understand, may be we can plan for this in future !
Thanks for your view