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

Add URL slugs to the CloudPebble IDE JavaScript #73

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AmandaCameron
Copy link

This allows one to go to /ide/projects/:id#settings to get to their project's settings. This adds a new CloudPebble.Locations API that handles the storage of valid slugs and calls a function to activate the proper slugs on the onhashchange event. It also includes a function to set the current slug in the URL.

To fix a bug, the Sidebar was disavowed of it's responsibility of resource and source file switching by callback, instead stuffing a valid slug into the a element it generates.

@Katharine
Copy link
Contributor

Please rebase on master.

This adds a simple routing system to the IDE / Project page that allows direct
linking to a file or resource, as well as to the settings, compilation, or
github panes. This is acclomplished by using the window.location.hash
property, and removes some of the burden from the sidebar's javascript
for managing the current view state.
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