Skip to content

Commit b49b8ba

Browse files
feat: add separate frontend module
The omap.frontend (django-)app is added to contain all frontend related stuff and assets, moved over from omap.core.
1 parent 8cf458a commit b49b8ba

File tree

18 files changed

+29
-9
lines changed

18 files changed

+29
-9
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,3 +130,6 @@ dmypy.json
130130

131131
!omap/theme/static/css/dist/
132132
/.idea/
133+
134+
# Generated / Compiled Frontend parts
135+
/omap/frontend/static/css/dist

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ help:
55

66
install:
77
# Install npm for theme
8-
cd omap/core/static_src && npm install
8+
cd omap/frontend/static_src && npm install
99

1010
frontend:
11-
cd omap/core/static_src && npm run build
11+
cd omap/frontend/static_src && npm run build
1212

1313
dev_server:
14-
cd omap/core/static_src && npm run start
14+
cd omap/frontend/static_src && npm run start

omap/core/templates/omap/core/tailwinddemo.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{% extends "omap/core/base.html" %}
1+
{% extends "omap/frontend/base.html" %}
22

33
{% block body %}
44
<div class="text-2xl text-green-500">

omap/core/urls.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
from omap.core import views
44

55
app_name = "core"
6+
67
urlpatterns = [
78
url("tw", views.TailwindDemoView.as_view()),
89
url("", views.demo),

omap/frontend/__init__.py

Whitespace-only changes.

omap/frontend/apps.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
from django.apps import AppConfig
2+
3+
4+
class CoreConfig(AppConfig):
5+
default_auto_field = "django.db.models.BigAutoField"
6+
name = "omap.frontend"
7+
8+
url_prefix = "frontend"
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)