Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8539005
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T11:15:33+00:00 2026-06-11T11:15:33+00:00

Specific question: this code works in a backbone template index.jst.eco, but it doesn’t work

  • 0

Specific question: this code works in a backbone template index.jst.eco, but it doesn’t work in index.jst.ejs

<ui>

<% for entry in @entries.models: %>
<li> <%= entry.get('name') %></li>
<% end %>

</ui>

I’d like to know why (i.e. how to fix it for ejs), and, more generally, is there comprehensive documentation for how to write code in ejs templates? I can’t find anything that goes into detail. As I’ve been playing around with ejs and eco, I’ve noticed the presence or absence of a : or a bracket can make a huge impact but I can’t figure out how to know what to use and when.

I’m willing to use jst.eco or jst.ejs depending on which syntax has better documentation.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T11:15:34+00:00Added an answer on June 11, 2026 at 11:15 am

    This is how that eco code would be written in jst.ejs.

       <% for (var i = 0; i < entries.length; i++) { %>
        <li> <%= entries.models[i].get('name') %></li>
        <% } %>
    

    However, I can’t get it to work with a for entry in entries.models iterator

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Apologies for this basic question, but I am noob stumped. The below code works
This is not a specific question but a generic question which was in my
This is a very narrow and specific question, but I know there are someone
This code works perfectly. I only have one question, I want to make it
I created this 2D Qlist. Code works but when I consider a bit deeper
There's code below, but this is also a conceptual issue. The question: Are the
This question may be a bit specific for stackoverflow, but here it is. I
i have this specific question to do to you, i have a database from
This question is specific to the iMacros suite in particular. What is the best
Sorry since this question is specific to my problem. While learning reflections i did

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.