-
Notifications
You must be signed in to change notification settings - Fork 12
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
fix no file / folder hidden when obsidian open #13
Conversation
Adding a little sleep (50ms) to wait for the dom after opening obsidian
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know this didn't exist when this pull request was initially made, so I understand why you did it the way you did, but I've added a style guide / contributing guidelines for the repo, if you can make the PR conform to the style guide I've set out, that would be greatly appreciated.
I didn't comment on each removed semicolon because that's excessive, but generally the functionality of the PR is good so it's just the style stuff that needs to be updated.
As I use eslint, maybe create an eslint configuration specific for the repo ? |
Ah, that'd be why, because I don't run eslint, I'll look into possibly adding an eslint config. For now only errors/warnings by the Typescript compiler or that happen directly in the Obsidian dev console are my main concerns. |
Hi. I notice this fix doesn't work on mobile. Don't know why :/ |
See #12
I added a little sleep
onLayoutReady
because, when Obsidian open, it returnnull
withquerySelector
.Waiting a little the DOM loading resolve this. I use a 50 ms, but 0 or 1 ms work too. As I was afraid of breaking Obsidian, I prefer to use 50 ms.
I also removed the unnecessary semicolon.