Skip to content

Add Recent Search History Feature for Better User Experience #152

@Adithyakp86

Description

@Adithyakp86

Title: Add Recent Search History Feature for Better User Experience

Description

Currently, users need to enter a city name every time they want to check the weather. Adding a recent search history feature would improve usability by allowing users to quickly access previously searched locations.

Problem

  • Users must repeatedly type city names.
  • No quick way to revisit recently searched locations.
  • Reduces convenience for frequent users.

Proposed Solution

Implement a "Recent Searches" section that:

  • Stores the last 5–10 searched cities.
  • Displays them below the search bar.
  • Allows users to click a city to fetch its weather data again.
  • Provides an option to clear search history.

Benefits

  • Improves user experience.
  • Reduces repetitive typing.
  • Makes navigation faster and more user-friendly.

Possible Implementation

  • Use Local Storage to save searched city names.
  • Retrieve and display saved cities on page load.
  • Update the list whenever a new city is searched.

Acceptance Criteria

  • Recent searches are saved in Local Storage.
  • Previously searched cities are displayed.
  • Clicking a city fetches its weather information.
  • Clear history option is available.
  • Feature works across page refreshes.

Labels

enhancement
good first issue
hacktoberfest

Metadata

Metadata

Assignees

Labels

Level 3medium priority or minor severityNSoCOpen source contribution

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions