camdendotlol / topstersorg

Book and music charts
https://topsters.org
GNU Affero General Public License v3.0
18 stars 9 forks source link

Feature: Redirect ostrakon.xyz to topsters.org and transfer data #11

Closed camdendotlol closed 1 week ago

camdendotlol commented 2 years ago

The redirect would be simple enough, but charts are stored in the user's browser on a per-domain basis and I don't want people to lose their charts.

I've read before about a way to load the old site in an iframe and run some JS that transfers the data to the new site. There would need to be something like

if (window.location.hostname.includes('ostrakon')) {
  sendCharts()
} else {
  recieveCharts()
}

For a recent example, I think this is how Wordle transferred everyone's data when it moved to nytimes.com.

Alternatively, since the import/export feature was added, I could prompt users to export their charts with a deadline.

camdendotlol commented 2 months ago

Now that users can export and import charts, it would be easier to just put up a notice for a while telling people to migrate their charts themselves with a scheduled shutdown date for the old domain.