An elegant, developer-themed counter web application built with pure vanilla JavaScript, semantic HTML5, and advanced modern CSS3. Styled with an Ayu-Dark IDE/terminal aesthetic, this project demonstrates clean separation of concerns, solid mental models for JavaScript memory references, and zero-dependency DOM manipulation.
- Terminal / IDE Aesthetics (100% CSS):
- Custom macOS-style traffic light window controls created purely via CSS gradients.
- Tab title header (
counter.js) and live terminal prompt (> ready_) with a blinking cursor animation. - Code syntax presentation using JetBrains Mono & IBM Plex Mono fonts:
- Heading rendered as a comment:
// Welcome to the counter game - Counter value styled as a live variable declaration:
let count = 0; - Interactive buttons styled as CLI commands (
> Increase,> Reset,> Decrease).
- Heading rendered as a comment:
- Clean Architecture & Decoupled State:
- State in Memory: JavaScript memory (
let count = 0) is the single source of truth. - DOM as Output Projection: The DOM is updated unidirectionally via
.textContentproperty mutation. - Reference Immutability: Uses
constpointers for fixed DOM element references.
- State in Memory: JavaScript memory (
- Micro-Interactions:
- Color-coded action buttons with subtle lift transitions on hover and active click compression.
- Full support for
prefers-reduced-motionaccessibility.
This project was built following a rigorous 10-phase engineering mentorship curriculum.
| Metric Category | Score | Result |
|---|---|---|
| Phases Completed | 10 / 10 |
100% Curriculum Completion |
| Average Metric Score | 5.0 / 5.0 |
Flawless Execution across all competencies |
| Misconceptions Resolved | 6 / 6 |
Fully mastered core browser & JS fundamentals |
| Competency | Score | Description |
|---|---|---|
| Requirements Precision | 5.0 / 5.0 |
Clean translation of functional requirements into deterministic execution logic. |
| Scope Discipline | 5.0 / 5.0 |
Zero architectural inflation; strictly adhering to vanilla web constraints. |
| Architectural Separation | 5.0 / 5.0 |
Complete decoupling of in-memory application state from view layer presentation. |
| Technical Vocabulary | 5.0 / 5.0 |
Precise distinction between primitives vs. objects and pointer references vs. mutations. |
| Variable Scope & Keywords | 5.0 / 5.0 |
Accurate usage of const for DOM nodes and let for reassigned state values. |
| Event Model Understanding | 5.0 / 5.0 |
Comprehensive mastery of the single-threaded event loop and event listeners. |
| Pseudocode Logic Fidelity | 5.0 / 5.0 |
Implementation-agnostic behavioral pseudocode seamlessly mapped to code. |
| Debugging & Verification | 5.0 / 5.0 |
Exhaustive edge case validation, test matrices, and deterministic state testing. |
[User Click Event] βββΊ [Event Listener Callback] βββΊ [Mutate State: count++] βββΊ [Project to DOM: countDisplay.textContent = count]
[JS Memory Heap]
βββ countDisplay (const reference address) βββΊ Points to <h1> DOM Node Object in Browser Memory
βββ count (let primitive number) βββΊ Holds current state integer (e.g., 0, 1, -1)
- Page Load: The browser parses HTML, constructs the DOM tree, paints initial HTML elements, and attaches event listeners.
- User Interaction: Clicking a button triggers an event listener callback.
- State Transition: The primitive variable
countis updated in JavaScript memory. - View Synchronization:
countDisplay.textContentis assigned the updated count value, prompting the browser to re-render the text.
P---Counter-Program/
βββ assets/
β βββ counter-app-ui.png # UI screenshot of the application
β βββ performance-metrics.png # Performance evaluation chart
βββ index.html # Semantic HTML5 markup
βββ style.css # Ayu-Dark terminal styling & animations
βββ index.js # Core counter logic & event handlers
βββ LEARNING_LOG.md # Detailed engineering mentorship log
βββ README.md # Project documentation
No package managers or external build tools required! Works directly in any modern web browser.
- Clone or download this repository:
git clone https://github.com/Muazislam/Minor-Project-JS----Counter-Program.git
- Navigate to the project directory:
cd Minor-Project-JS----Counter-Program - Open
index.htmlin your favorite browser:# On Linux: xdg-open index.html # On macOS: open index.html # Or serve using VS Code Live Server / any local HTTP server
- HTML5 β Semantic, clean markup structure.
- CSS3 β Custom properties, CSS Grid / Flexbox, pseudo-elements (
::before,::after), keyframe animations. - Vanilla JavaScript (ES6+) β Event handling, DOM manipulation, arrow functions, template literals.
- Muaz Islam Babar β GitHub Profile
- Project Log: LEARNING_LOG.md

