{"id":20425986,"url":"https://github.com/dfischer/rails-embrace-javascript","last_synced_at":"2025-04-12T19:02:34.501Z","repository":{"id":10566597,"uuid":"12770791","full_name":"dfischer/Rails-Embrace-Javascript","owner":"dfischer","description":"The web is evolving. Javascript is used no matter how you cut it. Let's use javascript *the right way*. This is a collection of best-practices across many JS frameworks with Rails.","archived":false,"fork":false,"pushed_at":"2014-01-24T21:42:21.000Z","size":240,"stargazers_count":9,"open_issues_count":1,"forks_count":0,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-26T13:12:23.286Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","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/dfischer.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}},"created_at":"2013-09-11T23:57:49.000Z","updated_at":"2019-11-20T08:15:35.000Z","dependencies_parsed_at":"2022-09-09T20:31:36.602Z","dependency_job_id":null,"html_url":"https://github.com/dfischer/Rails-Embrace-Javascript","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfischer%2FRails-Embrace-Javascript","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfischer%2FRails-Embrace-Javascript/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfischer%2FRails-Embrace-Javascript/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfischer%2FRails-Embrace-Javascript/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dfischer","download_url":"https://codeload.github.com/dfischer/Rails-Embrace-Javascript/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248618280,"owners_count":21134200,"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":[],"created_at":"2024-11-15T07:14:53.065Z","updated_at":"2025-04-12T19:02:34.469Z","avatar_url":"https://github.com/dfischer.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# What is this?\n\nSimilar to how www.todomvc.com shows how to use various frameworks. Rails Embrace Javascript will follow on that note with Rails specific examples, as well as a more complicated back-end.\n\nThis project is in the very early stages. Right now we're brainstorming possible ways to handle this project.\n\n## Overall project goal: Build a timesheet application.\n\nWe want the application to be complex enough that it won't be as basic as using one model, like todomvc.\n\nWe want the application to use as least 3 models during interaction.\n\n# Proposed flow:\n\nWhen interacting with the application, a user can create a project.\nA user should be able to associate people to that project.\nEach person listed on that project should have the ability to \"record timesheets\" per a day, and up to multiple times a day.\n\nThe idea is to do as much of this on one page as possible. We want to eliminate the \"new/edit\" views as being separate views. Everything should be inline and happen on the project page itself. In place editing of fields. Dynamically adding people and time_logs without refreshing.\n\nA user clicks new project. They're already working with the project and they can dynamically add people to the project and immediately record hours against that person.\n\n# Architecture:\n\n## Back-end + Front-end architecture for examples\n\n1) Rails as an api as one app. Each \"JS Framework\" as a Rails app + that JS framework.\n\n```\nrails-embrace-javascript/\n  timesheet-api/\n  timesheet-ember/\n  timesheet-angular/\n  timesheet-batman/\n  timesheet-omakase # the rails way, turbolinks, etc...\n```\n\n2) Rails back-end as an engine. Each JS framework loaded on top of that engine.\n```\nrails-embrace-javascript/\n  timesheet-core/\n  timesheet-ember/\n  timesheet-angular/\n  timesheet-batman/\n  timesheet-omakase/ # the rails way, turbolinks, etc...\n```\n\nNumber 1 is probably more likely to be a real-world scenario. Why have two apps? Why have the JS framework + Rails? So you get the rails/ruby eco system.\nIf we wanted to an app that is just the omakase way, it seems only #2 is an option?\n\nRepo will contain a folder for each implementation.\n\nReasons to have JS + Rails app:\n\n1. Rails Ecosystem\n2. Coffeescript\n3. Spider-friendly views (can output on initial load from server-side).\n\n## Back-end architecture modeling\n\n```\nProject\n  has_many :people\nPerson\n  belongs_to :project\n  has_many :time_logs\nTimeLog\n  belongs_to :project\n  belongs_to :person\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdfischer%2Frails-embrace-javascript","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdfischer%2Frails-embrace-javascript","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdfischer%2Frails-embrace-javascript/lists"}