Skip to content

refactor: Remove store.js (use localStorage) #550

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 21, 2018
Merged

refactor: Remove store.js (use localStorage) #550

merged 1 commit into from
Jan 21, 2018

Conversation

sorin-davidoi
Copy link
Contributor

@sorin-davidoi sorin-davidoi commented Jan 16, 2018

Shouldn't cause any issues with the browsers listed in RFC 1985. The only gotcha is Safari, where localStorage methods throw errors in Incognito Mode (this will fail gracefully, but the changes won't be saved - I would say this is not an issue since it is Incognito Mode after all).

Closes #548.

@sorin-davidoi
Copy link
Contributor Author

I've tested this in:

  • Firefox (including Private Mode)
  • Chrome (including Incognito)
  • Epiphany (including Private browsing) - WebKit based, closed thing to Safari I have to test

@sorin-davidoi sorin-davidoi mentioned this pull request Jan 18, 2018
@Michael-F-Bryan
Copy link
Contributor

One of the tests references Theme's store_js field which no longer exists, hence why travis is complaining.

@Michael-F-Bryan
Copy link
Contributor

It looks like there are merge conflicts in book.js. Would you be able to resolve them, @sorin-davidoi?

@sorin-davidoi
Copy link
Contributor Author

@Michael-F-Bryan, yes, just did 👍

@Michael-F-Bryan Michael-F-Bryan merged commit 0bc3544 into rust-lang:master Jan 21, 2018
@sorin-davidoi sorin-davidoi deleted the remove-store branch January 21, 2018 23:15
@Michael-F-Bryan
Copy link
Contributor

I think this may have broken themes the first time you load a book because local storage is handled differently. Once you change the theme local storage will be updated and you'll never see the missing styles again.

I've created an issue for this, #573.

Ruin0x11 pushed a commit to Ruin0x11/mdBook that referenced this pull request Aug 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants