Skip to content

Add statistics export (CSV/JSON) #9

@niklasmarderx

Description

@niklasmarderx

What

Add a button on the Statistics page to export typing history and performance data as CSV or JSON.

Why

Users who want to track their progress externally (spreadsheets, personal dashboards) need a way to export their data.

How

  1. Look at src/pages/StatisticsPage.ts for the current stats display
  2. Add an "Export" button to the page
  3. Collect data from StorageService (sessions, WPM history, accuracy)
  4. Format as CSV or JSON
  5. Trigger a browser download using Blob + URL.createObjectURL

Example:

const blob = new Blob([csvContent], { type: 'text/csv' });
const url = URL.createObjectURL(blob);
const a = document.createElement('a');
a.href = url;
a.download = 'keyboardwriter-stats.csv';
a.click();

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions