From bcca11aab954be05861f109e55eb8df01944ec12 Mon Sep 17 00:00:00 2001 From: Kumi Date: Fri, 15 Mar 2024 15:06:15 +0100 Subject: [PATCH] refactor(js): streamline frontend SCSS import Migrated the SCSS import for the frontend directly into editor.js and userarea.js from frontend.js, removing redundancy by consolidating style imports. This adjustment enables more coherent management of SCSS files and removes the need for a separate frontend bundle. Consequently, frontend.js and its references in HTML templates were removed to clean up the codebase and simplify the asset pipeline. These changes should make future maintenance of CSS easier and improve load times by reducing unnecessary scripting and network requests. --- assets/js/editor.js | 9 ++++++++- assets/js/frontend.js | 1 - assets/js/userarea.js | 1 + quackscape/tours/templates/tours/scene_edit.html | 5 ----- quackscape/users/templates/users/base.html | 1 - webpack.config.js | 1 - 6 files changed, 9 insertions(+), 9 deletions(-) delete mode 100644 assets/js/frontend.js diff --git a/assets/js/editor.js b/assets/js/editor.js index aaccd38..55238aa 100644 --- a/assets/js/editor.js +++ b/assets/js/editor.js @@ -1,6 +1,7 @@ import { getScene, getSceneElement, getCategory } from "./api"; import { populateDestinationDropdown } from "./editor/teleport"; +import "../scss/frontend.scss"; import "../css/editor.css"; let clickTimestamp = 0; @@ -94,6 +95,9 @@ function startModifyElement(event) {
+