-
Notifications
You must be signed in to change notification settings - Fork 942
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
Match paths with regexes #141
Comments
It's not possible but we'll consider it. Pull request welcome. P.S.: I changed the issue title from |
Right, better title. It looks like you can somehow override isRedirect with a custom function today, is that true? |
Yes, you can do that. |
@evanleonard right after you create an instance of your tour, you can simply redefine var tour = new Tour();
// override default method
tour._isRedirect = function() {
// custom _isRedirect logic
}; hope it helps. |
@evanleonard are you gonna submit a pull request for the original purpose of the issue? can i instead close this issue? |
Go ahead and close this. I was able to do what I need by overriding _redirect for now. |
Why not submit a pull request? Matching with regexes is a very useful feature. ;) |
I would also like to see a pull request :) |
👍 i obviously prefer to receive a shiny pull-request as well! |
As would I, of course. But time is limited, and i was able to solve my issue another way for now. FWIW, here is my workaround: this.tour._isRedirect = function(path, currentPath) { Basically is accepts any path that starts with the value of the path option on the step. Then I also needed to get the tour to sync to the right step when the user goes to the new page, so added the following method in the flow: _syncStep: function() { On Sep 29, 2013, at 1:04 PM, Emanuele notifications@github.com wrote:
|
Fixed in 1a82a2b. You cannot set the path option to a value like |
after redirect dont function the tour... help me please! |
Hi again, I'm trying to use the "path" parameter, but running into an issue where my paths look like "/users/5647".
is it possible today to have a path like "/users/*" that will match the above current_path?
What I'm getting right now is an infinite redirect loop =(
The text was updated successfully, but these errors were encountered: