Skip to content

Commit

Permalink
Move render actioncable partial into view layout file (#19)
Browse files Browse the repository at this point in the history
Move render actioncable partial into view layout file to fix issues with 404s and general board bugginess after updating the page content via Javascript (introduced in #16)
  • Loading branch information
westonganger authored Dec 5, 2024
1 parent 0e05f5f commit 6e3561f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### Unreleased
- [View Diff](https://github.com/westonganger/pairer/compare/v1.2.0...master)
- Nothing yet
- [#19](https://github.com/westonganger/pairer/pull/19) - Move render actioncable partial into view layout file to fix issues with 404s and general board bugginess after updating the page content via Javascript (introduced in [#16](https://github.com/westonganger/pairer/pull/16))

### v1.2.0 - Nov 20, 2024
- [View Diff](https://github.com/westonganger/pairer/compare/v1.1.0...v1.2.0)
Expand Down
3 changes: 3 additions & 0 deletions app/views/layouts/pairer/application.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ html
= javascript_include_tag 'rails-ujs'
= javascript_include_tag 'pairer/application'

- if controller.controller_path == "pairer/boards" && controller.action_name == "show"
= render "action_cable_script"

body
nav.navbar.navbar-inverse.navbar-fixed-top
.container-fluid
Expand Down
2 changes: 0 additions & 2 deletions app/views/pairer/boards/show.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -274,5 +274,3 @@ javascript:
window.init_sortable_lists();
});
= render "action_cable_script"

0 comments on commit 6e3561f

Please sign in to comment.