No puedo averiguar cómo recorrer el objeto de conexiones desde buscar usando x-for y Alpine JS para mostrar los 2 registros.
Intenté recorrer ${this.connections} con x-for pero obtuve un error de "objeto Objeto".
import { LitElement, html } from "../lit-all.min.js"; export class ContentDiv extends LitElement { constructor() { super(); this.connections; } static properties = { connections: {}, }; connectedCallback() { super.connectedCallback(); const dbPath = sessionStorage.getItem("dbPath"); fetch(`${dbPath}/connections/listConnections.php`, { method: "POST", headers: { "Content-Type": "application/json", } }) .then((response) => { return response.json(); }) .then((response) => { this.connections = response; }); } createRenderRoot() { return this; } render() { return html` <h1>Connections</h1> <div> <ul> ***Loop and display ${this.connections} here*** </ul> </div> `; } } customElements.define("content-div", ContentDiv);