Load home page

This commit is contained in:
Andros Fenollosa
2021-11-12 18:59:01 +01:00
parent 35e173697b
commit 04b1e5bf6c
8 changed files with 108 additions and 11 deletions

View File

@ -17,6 +17,20 @@
<script defer src="{% static "js/htmx.min.js" %}"></script>
</head>
<body>
{% block content %}{% endblock %}
<div class="container">
<header>
<nav>
<ul>
<li><strong>HTML over WebSockets with htmx</strong></li>
</ul>
<ul>
<li><a href="#">Events</a></li>
<li><a href="#">Profiles</a></li>
<li><a href="#">About</a></lif>
</ul>
</nav>
</header>
<main hx-ws="connect:ws:{{ DOMAIN }}/ws/pages/{{ room_random }}/" id="page"></main>
</div>
</body>
</html>

View File

@ -0,0 +1,3 @@
<main id="page">
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Corporis dignissimos dolor inventore laudantium libero optio quo reprehenderit repudiandae sapiente similique. Delectus dolorum enim fuga fugiat ipsam nam recusandae sequi sint.
</main>

View File

@ -1,5 +0,0 @@
{% extends 'layouts/base.html' %}
{% block content %}
Hola
{% endblock %}

View File

@ -0,0 +1,9 @@
<main id="page">
{% for talk in talks %}
<article>
<header>{{ talk.title }}</header>
<p></p>
<footer>Author {{ talk.author.full_name }} - {{ talk.category.name }}</footer>
</article>
{% endfor %}
</main>