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

Support partial :locals #1

Closed
bugeats opened this issue Apr 9, 2011 · 4 comments
Closed

Support partial :locals #1

bugeats opened this issue Apr 9, 2011 · 4 comments

Comments

@bugeats
Copy link

bugeats commented Apr 9, 2011

It appears that the handler ignores local variables passed to a partial.

@bartiaco
Copy link

bartiaco commented Jun 8, 2011

True that.

@olivernn
Copy link
Owner

olivernn commented Jun 9, 2011

Sorry, totally missed this one when it was raised, will take a look at it over the weekend.

@charlotte-miller
Copy link

Related Pull Request #2

@olivernn
Copy link
Owner

olivernn commented Jul 6, 2011

I have just pushed a new release which supports locals. Locals are available as variables within your templates and view classes.

<%= render :partial => "some partial", :locals => { :foo => "foo", :bar => "bar" } %>

Inside your template you can now just access foo and bar

<h1>{{foo}}</h1>

Let me know if you find any issues with this.

@olivernn olivernn closed this as completed Jul 6, 2011
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

No branches or pull requests

4 participants