How ahmadalmasalkhi/simple-interest-calculator works
Project type and purpose
• This is a static, single-page web application (no backend or database).
• Purpose: calculate simple interest based on user inputs (principal, rate, time) in the browser.
File structure
• index.html: the UI shell and layout.
• script.js: core business logic (compute interest, DOM updates).
README for additional insights
• HTML5, CSS3, vanilla JavaScript (ES6), and Bootstrap for styling.
• No external services or data stores—everything runs client-side.
Main components
a. User (Browser)
b. UI Layer
• index.html (Form controls: input field, slider, dropdown, button)
• style.css (Styling, responsive layout)
c. Logic Layer
• script.js (“compute()” function, input validation, calculation)
d. Output Display Area (DOM element where results appear)
Relationships and data flow
• (You may also show CSS applying styles to the UI/Form and Output Display)
Architectural patterns or principles
• Single-page application (SPA) pattern, though no routing.
• Separation of concerns: HTML for structure, CSS for presentation, JS for behavior.
• Event-driven interaction: user triggers compute() via button click.