From 1ed5a9aadf3907eec03d60758f64f1ea91422a77 Mon Sep 17 00:00:00 2001 From: Mees van der Wijk Date: Tue, 29 Apr 2025 18:17:25 +0200 Subject: [PATCH] Small fixes --- ImportantPrincipals.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ImportantPrincipals.md b/ImportantPrincipals.md index beae632..5652008 100644 --- a/ImportantPrincipals.md +++ b/ImportantPrincipals.md @@ -5,3 +5,8 @@ When creating the client side of a module there are some really important things - Never use document.getElementById or document.querySelector! Always use api.dom().querySelector so the element are always in the correct scope. - Never use event 'DOMContentLoaded' since the DOM content is always ready when the code is executed. - Never use event 'resize' instead use api.onResize() +- Never create HTML scaffolding like head, meta, title tags. The module html is already the body! +- Never use global scss styling, always try to use specific queries so it only applies to this module. +- Never style global elements like body, html, head, p, h1 etc.... +- Try to avoid using element ids as references as there can be multiple instances of a module at the same time. +- You do not need to specify