Closed ganeshkbhat closed 3 years ago
This is almost certainly a bug in your code. First of all, you testing for the existence of user
, and then trying to access users
. I am closing this issue. If you can create a minimal failing test that shows a bug in the EJS library itself, please feel free to open a new one.
Apologies for taking your time for something unrelated. I also use Python. I used Object.keys(users)
and the issue was resolved. My bad.
Is that possible? Using ejs:
I want to do something like this:
Getting an error:
My controller:
My index.ejs:
I am able to do this:
return response.render('index', { users: ["name", 25, "age", 25] })
name 25 age 25