{"id":21325605,"url":"https://github.com/juanpablo70/smarthomereact","last_synced_at":"2026-05-10T02:03:45.397Z","repository":{"id":204369662,"uuid":"711669132","full_name":"JuanPablo70/SmartHomeReact","owner":"JuanPablo70","description":"Smart Home: Light Control","archived":false,"fork":false,"pushed_at":"2023-11-06T00:36:12.000Z","size":232,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-15T23:43:23.606Z","etag":null,"topics":["hooks","react","usecontext-hook","usereducer-hook","vite"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JuanPablo70.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-10-30T00:11:13.000Z","updated_at":"2023-11-06T00:37:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"51a53524-da38-41a9-92a2-6b904b14aed2","html_url":"https://github.com/JuanPablo70/SmartHomeReact","commit_stats":null,"previous_names":["juanpablo70/smarthomereact"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/JuanPablo70/SmartHomeReact","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanPablo70%2FSmartHomeReact","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanPablo70%2FSmartHomeReact/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanPablo70%2FSmartHomeReact/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanPablo70%2FSmartHomeReact/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JuanPablo70","download_url":"https://codeload.github.com/JuanPablo70/SmartHomeReact/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanPablo70%2FSmartHomeReact/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264257676,"owners_count":23580469,"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","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":["hooks","react","usecontext-hook","usereducer-hook","vite"],"created_at":"2024-11-21T21:06:44.969Z","updated_at":"2026-05-10T02:03:45.312Z","avatar_url":"https://github.com/JuanPablo70.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Smart Home: Light Control - React Hooks\n\nThis project simulates a \"smart home\", empowering users to manage lights in different rooms through an interactive dashboard. Developed with ReactJS, this application showcases the use of useReducer and useContext hooks to handle the light state, delivering an efficient and user-friendly experience.\n\n### Prerequisites\n\nTo use this application, you need to have knowledge of:\n\n+ Node.js - Runtime environment for JavaScript.\n+ ReactJS - JavaScript library for building interactive and reactive user interfaces.\n\n### Installing and Running the Project\n\nTo download this project, run the following command down below.\n\n```\ngit clone https://github.com/JuanPablo70/SmartHomeReact.git\n```\n\nOnce the project is downloaded, open it in your favorite code editor such as VSCode and execute the following commands in the terminal:\n\n```\nnpm install\n\nnpm run dev\n```\n\nIn a web browser, visit the link [SmartHomeReact](http://127.0.0.1:5173/) to view the project.\n\n### Project Functionality\n\n![lights](img/lights.gif)\n\nUsers can turn lights on or off in specific rooms using individual buttons or control all lights at once with a global button.\n\nThe **useReducer** hook is employed to manage the light state, enabling smooth and controlled transitions between on and off states.\n\nThe **useContext** hook is utilized to provide access to the global light state throughout the application, simplifying its usage across different components avoiding prop drilling.\n\n### Build With\n\n+ [Vite](https://vitejs.dev) - Next Generation Frontend Tooling\n+ [React](https://es.react.dev) - The library for web and native user interfaces\n\n### Version\n\n1.0\n\n### Author\n\n[JuanPablo70](https://github.com/JuanPablo70)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuanpablo70%2Fsmarthomereact","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjuanpablo70%2Fsmarthomereact","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuanpablo70%2Fsmarthomereact/lists"}