Skip to content
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

Added Utils.readStorageJSON with relaxed JSON parser #3110

Merged
merged 4 commits into from Nov 24, 2023
Merged

Conversation

gfwilliams
Copy link
Member

Added Utils.readStorageJSON and relaxed JSON parser, and swap all interface.html over to using it.

This allows Bangle.js 2v20 (or cutting edge) and later to store a relaxed 'JSON' on internal storage which (while still normal JS) is smaller and faster (and preserves unicode better)

Fixes espruino/Espruino#2429

It'd be great if you could take a look over this as I had to change a bunch of files. I've tried some (eg openstmap) and they work ok, but it may well be I broke something :(

…erface.html over

to using it.

This allows Bangle.js 2v20 (or cutting edge) and later to store a relaxed
'JSON' on internal storage which (while still normal JS) is smaller and faster
(and preserves unicode better)

See espruino/Espruino#2429
@nxdefiant
Copy link
Contributor

nxdefiant commented Nov 23, 2023

tested read good on calendar, grocery, noteify, openstmap, sleepphasealarm, mylocation, sched, also with special character "\xFC" working

apps/openstmap/interface.html Outdated Show resolved Hide resolved
apps/owmweather/interface.html Outdated Show resolved Hide resolved
apps/owmweather/interface.html Outdated Show resolved Hide resolved
gfwilliams and others added 3 commits November 24, 2023 08:31
Co-authored-by: Rob Pilling <robpilling@gmail.com>
Co-authored-by: Rob Pilling <robpilling@gmail.com>
Copy link
Collaborator

@bobrippling bobrippling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks grand, shall leave to you to merge @gfwilliams in case you're wanting to time it with any other changes

@gfwilliams
Copy link
Member Author

Thanks! I won't push this to banglejs.com/apps until next week just in case ;)

@gfwilliams gfwilliams merged commit c7efd4f into master Nov 24, 2023
2 checks passed
@gfwilliams gfwilliams deleted the relaxed_json branch November 24, 2023 16:32
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.

special character on firmware 2v19.62 (seen on Bangle.Js2)
3 participants