Comments (9)
Hi Don,
I have spent some time trying to debug this, bit I haven't found the solution yet. Somehow the Dryml template engine does not enjoy using partial files.
Before spending more time on this, I wanted to ask you if you have tried this approach for Dryml partials:
partial.dryml:
<def tag="partial">
<h1>This is a partial</h1>
</def>
index.dryml
<include src="partial"/>
<partial/>
This is useful to split large Dryml files, but I don't know if it will cover your needs. What do you think?
from hobo.
More references to a similar partial issue: https://groups.google.com/forum/#!topic/hobousers/2zv9LxpzDJI
from hobo.
Hi Ignatio,
It took me a long time to get back to the partial problem. Most of my
partials are used to keep the dryml files at a managable size, so I
tried your suggestion and it works fine (for all of the places where I
have made the change).
Now I can translate all the remaining html files I had to use so that I
could use partials back to dryml.
Thanks for the hint.
Don
Hi Don,
I have spent some time trying to debug this, bit I haven't found the
solution yet. Somehow the Dryml template engine does not enjoy using
partial files.
Before spending more time on this, I wanted to ask you if you have tried
this approach for Dryml partials:
partial.dryml:
|
This is a partial
|index.dryml
|
|
This is useful to split large Dryml files, but I don't know if it will
cover your needs. What do you think?
from hobo.
I'm glad the workaround is useful for you Don.
I'm going to leave this open as low priority, without a milestone set.
from hobo.
Hi Ignacio,
Well, I hit the bug again, this time indirectly. I just added the
following code to index.dryml (enclosed in <script></script> and after a
javascript function that loads a google map (successfully)).
When 0 < mode > 3 (i.e. no partials are rendered) the code works fine.
If mode is set so one of the partials is rendered, it crashes the second
time the page is rendered (just like before).
There is another path in the program that reaches the same javascript
code via ajax (without hitting dryml) which works correctly.
Back to the drawing board :-( .
Don Ziesig
On 03/20/2014 05:36 AM, Ignacio Huerta wrote:
I'm glad the workaround is useful for you Don.
I'm going to leave this open as low priority, without a milestone set.
—
Reply to this email directly or view it on GitHub
#50 (comment).
from hobo.
Hi Don,
I'm afraid that Github removed the code from your comment, so I can't reproduce it. Could you try again pasting it directly through the Github interface? (#50 (comment))
In this link you can see how to format "fenced code blocks": https://help.github.com/articles/github-flavored-markdown.
Alternatively, just email the code to my personal email :).
Regards,
Ignacio
from hobo.
Moving up in priority: we should be able to fix this!
from hobo.
Thanks for that, Ignacio.
On Jan 3, 2014 1:18 PM, "Ignacio Huerta" [email protected] wrote:
Hi Don,
I have spent some time trying to debug this, bit I haven't found the
solution yet. Somehow the Dryml template engine does not enjoy using
partial files.Before spending more time on this, I wanted to ask you if you have tried
this approach for Dryml partials:partial.dryml:
This is a partial
index.dryml
This is useful to split large Dryml files, but I don't know if it will
cover your needs. What do you think?—
Reply to this email directly or view it on GitHubhttps://github.com//issues/50#issuecomment-31541903
.
from hobo.
Hi Ignacio. I, too, seem to have hit this very issue in Hobo 2.0.1. On a re-render (or refresh) of a DRYML page that calls a partial, I get the same crash. First time through is perfect.
<content-body:>
...
<%= render :partial => '/packages/payments', :locals => { :package => @package } %>
...
</content-body:>
</submit-page>
NoMethodError - undefined method _app_views_packages__payments_erb__2530908954951846704_70312386648420' for #<#Class:0x007fe5bbd072c8:0x007fe5c1f0b258>:
() Users/tgriffin/.rvm/gems/ruby-1.9.3-p545/bundler/gems/hobo-cda5c09aafa8/dryml/lib/dryml/template_environment.rb:642:in method_missing'
actionpack (3.2.12) lib/action_view/template.rb:145:in `block in render'
from hobo.
Related Issues (20)
- disabling #show action disables trashcan link in <bootstrap-table-actions/>
- Rails version HOT 2
- Use Jquery's "on" for the datepickers created live HOT 1
- Regression: NoMethodError - undefined method `validate' for "male":String HOT 7
- Status? HOT 1
- 'hobo new' using Hobo 2.2.4 fails on bundle install (under Ruby 2.2.2) HOT 4
- Incompatibility with current version of sprocket rails (3.0.0.) HOT 10
- Error: protected method `render' called for ... HOT 10
- NoMethodError - undefined method `map!' for #<ActiveRecord::Associations::CollectionProxy []> HOT 3
- ArgumentError, wrong number of arguments (5 for 4) HOT 7
- Compatibility to Rspec HOT 2
- Migration issue with latest Rails version HOT 2
- hobo_controller makes it unnecessarily hard to implement JSON APIs
- STI subclasses with lifecycle creators do not work HOT 2
- Would be nice if migrations had <Model>.reset_column_information statements
- Phantom card appears in the aside column when acting user not admin
- hot-input throws "no route" exception when relative_url_root is used
- Hobo do not integrate with web-console gem (missing method). HOT 1
- The heightStyle accordion option is missing from all the accordion tags
- How to get a copy of Hobo Rapid tag definitions HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hobo.