Passing values to partial

I was wonder about this:

<%- await include('/partials/_table', Object.assign({ title: "Departments/Units", name: "Departments" }, locals)) %>

Can I pass values to a partial like that? And if so, how do I access them within the partial? I’ve tried {{name}} and <%= name %> but neither seems to work, so not sure where the passed object is ending up.

Update: Ah ok, I was relying on the Wappler viewer itself. Testing the application in the browser shows it does work using <%= name %> or <%= locals.name %>.

Community Page
Last updated: