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
Implement passing through remove methods for E.show* #2286
Conversation
This looks good, thanks! My only worry is doing
Yes, it's there - if you go to http://www.espruino.com/Reference and click ⇒ next to the title it'll bring you to the right place :) Some methods can be used on Espruino boards like Pixl.js as well, so it could be worth noting in those cases that
If you can come up with some code to run and expected outcomes I can quickly run through it to test? |
That would be great. I can test the code by just running it on the Bangle 2, but I don't know how valid the results would be :)
Do you think that just checking the code in the repositories for this would be enough, or should I just move the object into a variable and conditionally add the remove property before giving it to setUI? |
I have added some documentation, but not quite sure on the syntax for the typescript definitions. Regarding the use of ['remove'] or similar a quick search had no results in Espruino and BangleApps repositories. It seems the back function is handled the same way and can be undefined:
|
For testing I have used this code:
Just uploaded that to RAM and then used various combinations of the following commands and interactions with the UI to check if the removal message is printed.
|
This looks great - thanks! I'll give it a quick test on Bangle.js 1 now |
Yes, seems to work for me! Merging... |
This implements additional options for using a remove method in
E.show*
. There are a few things missing as I was not sure if this approach is the correct one for cleaning up after those methods are done.