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

Close sidebar in a single page application #308

Closed
roboriaan opened this issue Oct 10, 2017 · 3 comments
Closed

Close sidebar in a single page application #308

roboriaan opened this issue Oct 10, 2017 · 3 comments

Comments

@roboriaan
Copy link

Is it possible to close the sidebar programmatically? I've tried adding #sidebar-close to one of the links in the side menu but it stays open. Now it's possible that it doesn't work because of hashbang routing that I use in my SPA. Only when I select the address bar and hit enter does it close.

@picturepan2
Copy link
Owner

@roboriaan Yes, I will add that in v0.4.5 this week.

@roboriaan
Copy link
Author

Thanks for this fantastic framework btw!

@picturepan2
Copy link
Owner

@roboriaan You can use the class active to open the off-canvas sidebar or remove the class to close it. https://github.com/picturepan2/spectre/releases/tag/v0.4.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants