Modernize codebase and fix security issues#1
Open
srivarshithdaladuli wants to merge 1 commit intomasterfrom
Open
Modernize codebase and fix security issues#1srivarshithdaladuli wants to merge 1 commit intomasterfrom
srivarshithdaladuli wants to merge 1 commit intomasterfrom
Conversation
- Update package.json: bump version to 2.0.0, update Express to ^4.21.0 - Remove unnecessary path package (Node.js has built-in path module) - Add dev script with --watch flag for development - Add Node.js engine requirement (>=18.0.0) - Fix critical security issue: replace eval() with safe expression parser - Add proper operator precedence handling in calculator - Add input validation to prevent malicious code execution - Add keyboard support for better usability - Add backspace functionality - Improve HTML semantics and accessibility (ARIA labels) - Remove duplicate AdSense script tag - Add meta description and theme-color - Modernize CSS with box-sizing reset - Add responsive design for mobile devices - Add reduced motion media query for accessibility - Improve button hover/focus states and transitions - Add health check endpoint to server - Add graceful shutdown handling for SIGTERM Co-Authored-By: Warp <agent@warp.dev>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR modernizes the codebase with security fixes, better accessibility, and updated dependencies.
Changes
Security
eval()vulnerability - Replaced unsafeeval()with a custom safe expression parser that validates input and properly handles operator precedenceDependencies
^4.17.1to^4.21.0pathpackage (Node.js has a built-inpathmodule)2.0.0>=18.0.0)JavaScript (
script.js)HTML (
index.html)<main>elementCSS (
style.css)box-sizing: border-boxresetprefers-reduced-motionmedia queryServer (
server.js)/healthendpoint for monitoringTesting
This PR was generated with Warp.