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

Include Location#hash in Path #68

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

Conversation

jherdman
Copy link
Contributor

@jherdman jherdman commented Jun 4, 2014

This will make Garlic friendlier to things like Ember.js

@jherdman
Copy link
Contributor Author

jherdman commented Jun 4, 2014

Two quick notes:

  1. I couldn't get the test suite to run on my local machine, and I was kind of hoping this would be a bit more automated (e.g. npm install ; npm test) — EDIT: I've added Improve Contribution Bootstrapping #69 to resolve this problem
  2. I haven't the foggiest clue how to add a test for this

@jherdman
Copy link
Contributor Author

jherdman commented Jun 4, 2014

Tests seem to be failing randomly, I'll investigate the issue soon. I think there's an issue with the test runner itself.

This will make Garlic friendlier to things like Ember.js
@jherdman
Copy link
Contributor Author

jherdman commented Jun 5, 2014

@guillaumepotier would you be interested in pairing on this with me? I can't figure out why this is failing, but I'm nearly 100% certain it has something to do with the way jQuery and Zepto are being loaded in the test runner.

@jherdman
Copy link
Contributor Author

jherdman commented Jun 5, 2014

This seems to be only a partial solution. There are two problems when using Ember:

  1. Without Location#hash, there could be conflicting entries in localStorage. Pretend, for example, that our application lives at this URL: example.com/app#/, and some forms take the URL example.com/app#/forms/<ID>. It's abundantly clear that without Location#hash keys may conflict.
  2. When submitting forms URLs such as the following are generated: example.com/app?blah-radio=One&blah-checklist%5BOne%5D=on&blah-checklist%5BThree%5D=on#/forms/123. It seems that intercepting the submit action is causing a conflict between Ember and Garlic.

@LorenzBischof
Copy link

Can we get this merged? Really useful if pushstate is not an option.

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