How sebin3/grupo-4-mini-calculadora-de-edad- works
Project type and purpose
• This is a small, client-side web application (“Mini Calculadora de Edad”) that runs entirely in the browser.
• Its purpose is to let users calculate their exact age from a birthdate and maintain a session-long history of those calculations.
File structure
• Top-level files only—no separate frontend/backend directories:
• index.html → page structure and entry point
• style.css → presentation layer (UI styling)
• script.js → main application logic (event handlers, DOM updates)
• api.js → simulated API module (in-memory storage of history)
• No real server or database; “api.js” abstracts data store operations.
README for additional insights
• Confirms use of HTML5, CSS3, ES6 modules.
• Describes key features: age calculation, in-memory history, UI updates.
Main components
a. Browser / Client Environment
b. UI Layer (HTML5 + CSS3)
c. Front-end Logic (script.js)
d. Simulated API Module (api.js)
e. In-Memory Data Store (inside api.js)
f. User (actor interacting with UI)
Relationships and data flows
• User → clicks “Calculate” → UI Layer (index.html)
• UI Layer → invokes → script.js (business logic)
• script.js → calls → api.js methods (store/retrieve history)
• api.js → reads/writes → In-Memory Data Store
• api.js → returns data → script.js → updates UI Layer
Architectural patterns and design principles
• Separation of concerns:
• Presentation (HTML/CSS)
• Business Logic (script.js)
• Data Access Layer (api.js simulating REST calls)
• Modular JavaScript using ES6 imports/exports.
Relevant technologies and frameworks
• HTML5 → static page
• CSS3 → styling
• JavaScript ES6 Modules → script.js and api.js
• No external frameworks (vanilla JS)