-
Notifications
You must be signed in to change notification settings - Fork 1
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
grunt.task.current.name #3
Comments
sweet jesus |
Sweet jesus what? |
Hmmn.. I thought we'd resolve the |
Yeah, you would want to pull it directly from where it is. Now that I think of it, I might be able to perform this traversal myself using the current syntax. I updated expander today to support explicitly defining Perhaps I can make grunt.task.current.name a getter that does some magic to find out where it is when it is gotten. |
Keep in mind, there's also |
blah. i guess a closure around the imports for template expansion is going to be the solution. |
actually, adding introspection into expander could be cool, though. any thoughts on a reasonable non-confusing syntax? |
I like the idea where you could access an array of path parts based on where you currently are, maybe (a) {
foo: {
bar: {
baz: '<%= __path[0] %>' // 'foo' (a)
qux: '<%= __path(1) %>' // 'bar' (b)
bla: '<%= __.path(-1) %>' // 'bla' (c)
}
}
} |
When we support running tasks concurrently, accessing this property is going to be a problem. I have an idea for a solution but I'm not sure what it should look like.
Instead of doing this:
We could do this:
The options-merged form would be this, which would resolve to
targetOne
The question I have is what is the best way to implement this introspection?
@cowboy / @shama ?
The text was updated successfully, but these errors were encountered: