{"id":23698315,"url":"https://github.com/ribafs/javascript-calculators","last_synced_at":"2026-04-12T22:39:12.923Z","repository":{"id":107204223,"uuid":"447288518","full_name":"ribafs/javascript-calculators","owner":"ribafs","description":"Examples from simple sum to scientific calculator","archived":false,"fork":false,"pushed_at":"2022-11-04T12:31:21.000Z","size":17,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-15T19:52:10.610Z","etag":null,"topics":["calculator","division","javascript","multiplication","operations","scientific","simple","subtraction","sum"],"latest_commit_sha":null,"homepage":"https://ribafs.github.io/javascript-calculators","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ribafs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-01-12T16:22:07.000Z","updated_at":"2022-11-07T18:54:09.000Z","dependencies_parsed_at":null,"dependency_job_id":"929bba11-414f-447f-a671-cc07a2ff9c3e","html_url":"https://github.com/ribafs/javascript-calculators","commit_stats":{"total_commits":14,"total_committers":1,"mean_commits":14.0,"dds":0.0,"last_synced_commit":"ed50307110322392dfc15f71a6107008c9386394"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ribafs/javascript-calculators","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ribafs%2Fjavascript-calculators","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ribafs%2Fjavascript-calculators/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ribafs%2Fjavascript-calculators/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ribafs%2Fjavascript-calculators/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ribafs","download_url":"https://codeload.github.com/ribafs/javascript-calculators/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ribafs%2Fjavascript-calculators/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272155146,"owners_count":24882983,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-25T02:00:12.092Z","response_time":1107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["calculator","division","javascript","multiplication","operations","scientific","simple","subtraction","sum"],"created_at":"2024-12-30T07:16:04.795Z","updated_at":"2026-04-12T22:39:07.894Z","avatar_url":"https://github.com/ribafs.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# javascript-calculator\n\n## Examples from simple sum to scientific calculator\n\n## Only sum and simple code\ncalc_sum.html\n\n### Example shared in Facebook group HTML, CSS and JS\n```\n\u003cscript\u003e\nconst add = (...nums) =\u003e alert(nums.reduce((a, b) =\u003e +a + +b));\nadd(...Array.from({length:2}, _ =\u003e prompt('Please enter a number...')));\n//Although if you only see it as 1 input for the entire equation, it could be even more direct.\nalert(eval(prompt('Please enter equation').replace(/[^%+-/*/(/)\\d+]/g, '')));\n\u003c/script\u003e\n```\nThank you Shawn John Genlloud\n\n## Four operations and simple code\ncalc_js.htm\n\n## Four operations and simplel and only one function and form\ncalc_js2.html\n\n## With keyboard and simple code\ncalc_js3.html\n\n## Scientific calculator\ncalc_cient.html\n\n## References\n\nhttps://stackoverflow.com/questions/60346902/i-cant-do-a-simple-calculator-with-javascript\n\nhttps://medium.com/@singhamritpal49/creating-simple-addition-calculator-with-javascript-563ede3527e2\n\nhttps://www.codigofonte.com.br/codigos/calculadora-em-html-e-javascript\n\nhttps://comodesenvolver.com.br/como-criar-uma-calculadora-cientifica-usando-html-javascript-e-css/\n\nhttp://www.devin.com.br/calculadoras-javascript/\n\n## License\n\nMIT\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fribafs%2Fjavascript-calculators","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fribafs%2Fjavascript-calculators","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fribafs%2Fjavascript-calculators/lists"}