-
-
Notifications
You must be signed in to change notification settings - Fork 251
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
Generate views as well as templates through Tilt #48
Comments
The value of generating a view for a template is that you can actually add some custom helpers on it and other stuff... |
If you vant to know, my opinion is that I don't see any value at all in generators... So I am not the best fitted person to answer. @patr1ck any input on this one? |
We're adding generators in order to cut down on the amount of "now create this file with this boilerplate" type work. The ember+rails tutorial that we're writing for the new ember.js website will use these extensively. I'm still a bit confused by what you're suggesting. The line of code you linked to seems to be related to the precompiling of handlebars template, so I'm not sure how it's relevant. To be clear, the view generator I added creates both a view.js file and a template.handlebars file. There's no template-only generator, nor is there a template generator that creates a view. I would agree that that wouldn't make much sense, as templates don't imply a view. |
Also, I'm still learning the various Ember.js internals, so I could very well just be totally misunderstanding what's going on here. |
I relay do not see the point of this. If any new arguments - reopen. |
I'm not sure I see the value of adding a separate 'view' file for each template file. Is anyone against auto-generating views based on templates and their file names?
Seems like this would fit well into the existing Tilt template right here:
https://github.com/btelles/ember-rails/blob/master/lib/ember/handlebars/template.rb#L19
If we get a few thumbs up, I'll go ahead and try to implement the feature.
The text was updated successfully, but these errors were encountered: