{"id":13755993,"url":"https://github.com/ThomasWeiser/todomvc-elmfire","last_synced_at":"2025-05-10T03:30:41.540Z","repository":{"id":35893098,"uuid":"40179454","full_name":"ThomasWeiser/todomvc-elmfire","owner":"ThomasWeiser","description":"TodoMVC+Firebase  in  Elm+ElmFire","archived":false,"fork":false,"pushed_at":"2016-06-16T20:06:36.000Z","size":384,"stargazers_count":60,"open_issues_count":1,"forks_count":13,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-04T00:24:18.224Z","etag":null,"topics":["elm","elmfire","firebase","todomvc"],"latest_commit_sha":null,"homepage":"http://thomasweiser.github.io/todomvc-elmfire/","language":"Elm","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ThomasWeiser.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}},"created_at":"2015-08-04T10:52:48.000Z","updated_at":"2023-06-16T06:31:52.000Z","dependencies_parsed_at":"2022-09-08T18:00:45.684Z","dependency_job_id":null,"html_url":"https://github.com/ThomasWeiser/todomvc-elmfire","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThomasWeiser%2Ftodomvc-elmfire","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThomasWeiser%2Ftodomvc-elmfire/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThomasWeiser%2Ftodomvc-elmfire/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThomasWeiser%2Ftodomvc-elmfire/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ThomasWeiser","download_url":"https://codeload.github.com/ThomasWeiser/todomvc-elmfire/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253358069,"owners_count":21895967,"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":["elm","elmfire","firebase","todomvc"],"created_at":"2024-08-03T11:00:33.876Z","updated_at":"2025-05-10T03:30:41.218Z","avatar_url":"https://github.com/ThomasWeiser.png","language":"Elm","funding_links":[],"categories":["Examples"],"sub_categories":["Other editors"],"readme":"# TodoMVC in Elm + ElmFire • [Demo](https://thomasweiser.github.io/todomvc-elmfire/)\n\n[TodoMVC](http://todomvc.com/)\nimplemented in\n[Elm](http://elm-lang.org/),\nextending [Evan Czaplicki's](https://twitter.com/czaplic)\n[version](https://github.com/evancz/elm-todomvc),\nusing [Firebase](https://www.firebase.com/)\nvia [ElmFire](https://github.com/ThomasWeiser/elmfire)\nand [elmfire-extra](https://github.com/ThomasWeiser/elmfire-extra)\nfor storage and real-time collaboration.\n\n## Build Instructions\n\nThis app needs the Elm plattform version 0.16. Compile with:\n\n    elm make --yes --output js/elm.js src/TodoMVC.elm\n    \nThen open `index.html` in your browser. The app should connect\nto the shared Firebase and retrieve the current list of items.\n\nAlternatively use the enclosed `Makefile` on Unix-like machines:\n\n    make all open\n    \n## Architectural Overview\n\nThe app complies with [The Elm Architecture](https://github.com/evancz/elm-architecture-tutorial/),\nusing [evancz/start-app](http://package.elm-lang.org/packages/evancz/start-app/2.0.0/)\nand [evancz/elm-effects](http://package.elm-lang.org/packages/evancz/elm-effects/1.0.0).\n\nA sketch of the data flow:\n\n- Inputs are coming from\n    - Firebase changes\n    - user interaction\n- The `model` comprises two parts\n    - shared persistent state, mirrored from Firebase by means of `ElmFire.Dict`\n    - local state (filter settings, intermediate edit state)\n- An `update` function takes an input event and the current model, returning\n  a new model and possibly an effect, i.e. a task to change the Firebase data (using `ElmFire.Op`).\n- A `view` function renders the current model as HTML\n\nPlease note that content changes made by the user always flow through the Firebase layer.\nFrom there they a passed down to the new model.\nThis utilizes the fact that the Firebase library immediately reflects local writes\nwithout waiting for a server round trip.\n\nFirebase queues up write operations during a network outage.\nSo the app will work offline and will catch up after going online again.\n\nFor adding new items the app uses Firebase's\n[*push* operation](https://www.firebase.com/docs/web/api/firebase/push.html),\nwhich generates chronologically sorted unique ids.\nThe model uses a dictionary\nto map these ids to the items' payload.\n\n## Future Work\n\n- Explore architectural variations\n    - Componentize the model: split it into a shared part and a local part\n      where the local part depends on the shared part but not the other way round.\n- Possibly structure the code into components, as outlined in [The Elm Architecture](https://github.com/evancz/elm-architecture-tutorial/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThomasWeiser%2Ftodomvc-elmfire","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FThomasWeiser%2Ftodomvc-elmfire","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThomasWeiser%2Ftodomvc-elmfire/lists"}