Questions tagged [eco]

Embedded Coffeescript (ECO) templates lets you embed coffeescript directly in your templates.

Embedded Coffeescript (ECO) templates lets you embed coffeescript directly in your templates.

ECO templating documentation and code are available at https://github.com/sstephenson/eco.

59 questions
0
votes
0 answers

ODOO ECO after rejected ,BOM or Product cannot recovery initial version

I changed BOM in ECO. But when user rejected, it did not rollback? Bug or my operation is short of step. Can give me some advice. apply change and apply rebase did not work
0
votes
2 answers

Basic DocPad: variables and first errors

What I don't understand: certain keywords appear to be reserved for DocPad like @document, which words let me use custom data values? e.g. I'm using <%= data.hostimagesurl %> but I've seen <%= page.hostimagesurl %> and <%= site.hostimagesurl %>…
cyttl
  • 1
  • 2
0
votes
1 answer

Using Django template divisibilityby tag with .eco template?

Technologies: Django/Python, Coffeescript/Eco Templates/Backbone.js. Eco templates: https://github.com/sstephenson/eco I'm using .eco templates with backbone to populate my django views. So, Django has its ways of counting iterations, etc. -- which…
Michael Sebastian
  • 785
  • 3
  • 15
  • 33
0
votes
1 answer

Docpad: get collection item dynamically

I am new to docpad. I have something like filter in my project. There is few switchers to filter a list of icons. After user clicks an icon, the details about chosen item should be shown. This item is in docpad collection. How to implement this?…
mstmustisnt
  • 333
  • 4
  • 13
0
votes
1 answer

How to display associated JSON data together in a backbone.js .eco template

So here is my JSON data; { "team_name": "New Team!", "user_name": "hey_user", "games": [] }, { "team_name": "New Team!", "user_name": "testing_user", "games": [] }, { …
Michael Sebastian
  • 785
  • 3
  • 15
  • 33
0
votes
1 answer

Is there any way to require meta data in DocPad with eco?

At the moment, I'm setting up a new DocPad-project and I explicitly require certain meta data to be set. If not set, I want DocPad to give me some sort of warning, alas I can't find any hints online on how to set it up. My file default.html.eco…
Patrick
  • 397
  • 3
  • 3
0
votes
1 answer

Unable to use findAll() to search sub-directories

I'm using an eco renderer within Docpad (building a site based on https://github.com/zenorocha/browser-diet) In it, I need to find all the documents in a particular sub-directory. The directory structure is: /src/documents/test1/test2 I need to find…
0
votes
1 answer

Filtering @getFilesAtPath results in Docpad

In Docpad, the following code (using a Query-Engine helper and eco) pulls a list of file names from a directory tree and addds their url to an array: <% images = []; %> <% for file in @getFilesAtPath({relativeOutDirPath: 'images/'}).toJSON() : %> …
fraxture
  • 5,113
  • 4
  • 43
  • 83
0
votes
1 answer

Rails link_to in eco template

I'm trying to create a link in an eco template using Backbone Marionette with a rails backend. I'm trying to let the user download the data in CSV/XLS. If I was in a regular rails view I could do <%= link_to "CSV", surveys_path(format: "csv")…
Tom Hammond
  • 5,842
  • 12
  • 52
  • 95
0
votes
1 answer

Eco templates - Some artefacts in code

Using eco template I form follow code: <% if @is_completed : %> completed <% end %> But after rendering I see some artifacts in my code:
completed …
senyOr
  • 1
  • 3
0
votes
1 answer

Perform for loop using eco with increment and metadata usage

I'm using docpad and on index page, in navigation pane I want to get a list of links grouped by category. Category is defined in each markdown document in meta info on top. For example category:"tutorials" So I have this: <% for docu in…
Lukasz Gornicki
  • 609
  • 4
  • 12
0
votes
1 answer

How to use a collection of partials to insert partials based on the url?

I'm using docpad with the eco templating engine and the partials plugin. The point of this is to insert a list of snippets into a landing page. The logical approach (to me) is to iterate through a collection of the snippets and insert each…
Metalskin
  • 3,998
  • 5
  • 37
  • 61
0
votes
1 answer

How to use Rails routes and helpers in Backbone?

I want to use Devise helpers and routes in my Backbone.js code: user_signed_in? user_omniauth_authorize_path(:provider) destroy_user_session_path, method: :delete Normally, in my Rails views I can do: <% if user_signed_in? %>
  • <%= link_to…
  • tenaz3.comp
    • 367
    • 6
    • 17
    0
    votes
    1 answer

    Marionette's view can't be inserted in Backbone.Modal

    I tried to use this backbone extension for making stackable modals. http://awkward.github.io/backbone.modal/ It says is compatible with Marionette and so i been trying to use it with views that i create with it. But the problem it seems that it…
    0
    votes
    0 answers

    Spine.List not rendering in the view

    I'm working on a SpineJs app that has the following setup: Posts (essentially chat rooms), which each have multiple messages in them, exactly like a text message stream, or even a chat room stream. I am having problems getting the Spine.List…
    Pete
    • 1,472
    • 2
    • 15
    • 32