Language
English English Arabic (العربية) Arabic (العربية) Bengali (বাংলা) Bengali (বাংলা) Czech (Čeština) Czech (Čeština) German (Deutsch) German (Deutsch) Spanish (Español) Spanish (Español) Persian (فارسی) Persian (فارسی) French (Français) French (Français) Hebrew (עברית) Hebrew (עברית) Hindi (हिन्दी) Hindi (हिन्दी) Indonesian (Bahasa Indonesia) Indonesian (Bahasa Indonesia) Italian (Italiano) Italian (Italiano) Japanese (日本語) Japanese (日本語) Korean (한국어) Korean (한국어) Malay (Bahasa Melayu) Malay (Bahasa Melayu) Dutch (Nederlands) Dutch (Nederlands) Polish (Polski) Polish (Polski) Portuguese (Português) Portuguese (Português) Romanian (Română) Romanian (Română) Russian (Русский) Russian (Русский) Swahili (Kiswahili) Swahili (Kiswahili) Tamil (தமிழ்) Tamil (தமிழ்) Thai (ไทย) Thai (ไทย) Turkish (Türkçe) Turkish (Türkçe) Ukrainian (Українська) Ukrainian (Українська) Urdu (اردو) Urdu (اردو) Vietnamese (Tiếng Việt) Vietnamese (Tiếng Việt) Chinese (简体中文) Chinese (简体中文) Chinese Hong Kong (繁體中文) Chinese Hong Kong (繁體中文) Taiwan (繁體中文) Taiwan (繁體中文)

Demo App

A simple demonstration app showing the basic structure of modular apps with ES6 modules, clean CSS organization, and best practices.

Hello, Developer!

This is a simple demonstration app

This app demonstrates the basic structure of a modular app with CSS/JS organization.

Introduction

Welcome to Demo App — a simple demonstration application designed specifically for developers learning the InviCMS App Module structure.

 

Learning Purpose

A minimal example showing modular CSS, ES6 JavaScript, basic interactions, and clean structure following best practices.
 

Perfect For

Understanding app structure, learning modular organization, and using as a quick reference when creating new apps.
Key difference: Unlike functional apps (Calculator, Unit Converter), Demo App is intentionally simple and designed as a learning reference, not a production tool.

How It Works

Basic Functionality

1

Input Field

Enter your name

2

Say Hello

Updates greeting with your name

3

Reset

Clears input and resets greeting

Code Structure

Frontend Architecture

 
JavaScript Module Structure
js/apps/demo-app/
├── demo-app.js              ← Entry point
└── modules/
    ├── DemoApp.js           ← Main coordinator
    ├── DemoAppDisplay.js    ← Display updates
    └── DemoAppHandlers.js   ← Event handlers

Styling Architecture

 
CSS Module Structure
css/apps/demo-app/
├── demo-app.css             ← Main import file
├── _container.css           ← Container styles
├── _greeting.css            ← Greeting section
├── _controls.css            ← Controls (input, buttons)
├── _info.css                ← Info box
└── _responsive.css          ← Mobile adjustments

Key Features

  • Separation of Concerns: Display logic separate from event handling
  • Multilingual Support: All text uses __d() function
  • Input Validation: Shows alert if name is empty
  • Keyboard Support: Press Enter to greet

For Developers

Using as a Template

1

Copy Structure

Duplicate the controller, view, CSS, and JavaScript files from Demo App.

2

Rename Files

Replace "DemoApp" with your app name throughout all files and classes.

3

Add Logic

Implement your app's specific functionality in the modules.

4

Customize Styles

Update colors, layout, and responsive breakpoints for your design.

Best Practices Demonstrated

CSS Best Practices

  • Main file imports all partials with @import
  • Each component in separate file (e.g., _controls.css)
  • Responsive styles in dedicated _responsive.css
  • BEM-like naming convention: .demo-app-container, .demo-btn

JavaScript Best Practices

  • ES6 modules with import/export statements
  • Main class coordinates sub-modules
  • Display logic separate from event handlers
  • Clear method naming: handle*(), init(), bind*()

Multilingual Implementation

  • All text wrapped in __d() function
  • Proper key prefixing: app.demo.key
  • Default values provided for fallback

Documentation & Resources

 
App Module Guide
Documentation
site/Modules/App/README.md
 
How to Add App
Tutorial
site/Modules/App/HOW_TO_ADD_APP.md
Start typing to search...
Searching...
No results found
Try searching with different keywords