Skip to content

Commit 2d88de5

Browse files
committed
refactor: remove rails4-autocomplete and jquery-ui-rails
Removes rails4-autocomplete (12+ years unmaintained) and jquery-ui-rails dependencies that have been non-functional since April 2022. The autocomplete feature for the skill_list field was accidentally broken during Bootstrap 5 migration (PR #1745) and has remained broken for nearly 3 years without user complaints. Analysis confirmed: - Feature broken since April 2022 (Bootstrap 5 migration) - Zero usage of jQuery UI widgets across entire codebase - Both gems added together in 2015 exclusively for autocomplete - No test coverage for autocomplete functionality - skill_list field continues working with manual comma-separated entry Removes: - rails4-autocomplete gem (last updated April 2014) - jquery-ui-rails gem (single-purpose dependency) - Controller autocomplete declaration - Autocomplete route endpoint - JavaScript and CSS requires Bundle size savings: ~120KB Closes #2445 Documentation: docs/rails4-autocomplete-investigation.md
1 parent 70c024d commit 2d88de5

6 files changed

Lines changed: 0 additions & 17 deletions

File tree

Gemfile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ gem 'friendly_id'
2323
gem 'haml'
2424
gem 'high_voltage'
2525
gem 'jquery-rails'
26-
gem 'jquery-ui-rails'
2726

2827
# Use Active Storage variant
2928
gem 'image_processing'
@@ -37,7 +36,6 @@ gem 'pickadate-rails'
3736
gem 'premailer-rails'
3837

3938
gem 'pundit'
40-
gem 'rails4-autocomplete'
4139
gem 'reline' # LOCKED: Added because of readline is not part of Ruby 3.5.0
4240
gem 'rolify'
4341
# Use Sass to process CSS

Gemfile.lock

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -285,8 +285,6 @@ GEM
285285
rails-dom-testing (>= 1, < 3)
286286
railties (>= 4.2.0)
287287
thor (>= 0.14, < 2.0)
288-
jquery-ui-rails (6.0.1)
289-
railties (>= 3.2.16)
290288
json (2.18.0)
291289
jwt (2.7.1)
292290
language_server-protocol (3.17.0.5)
@@ -460,8 +458,6 @@ GEM
460458
rails-html-sanitizer (1.6.2)
461459
loofah (~> 2.21)
462460
nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0)
463-
rails4-autocomplete (1.1.1)
464-
rails (>= 3.0)
465461
rails_semantic_logger (4.19.0)
466462
rack
467463
railties (>= 5.1)
@@ -682,7 +678,6 @@ DEPENDENCIES
682678
importmap-rails
683679
irb
684680
jquery-rails
685-
jquery-ui-rails
686681
launchy
687682
letter_opener
688683
listen (~> 3.10)
@@ -705,7 +700,6 @@ DEPENDENCIES
705700
rack-mini-profiler (~> 4.0)
706701
rails (~> 8.1.2)
707702
rails-html-sanitizer (~> 1.6.2)
708-
rails4-autocomplete
709703
rails_semantic_logger
710704
reline
711705
rolify

app/assets/javascripts/application.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
//= require jquery
1616
//= require rails-ujs
1717
//= require activestorage
18-
//= require jquery-ui
19-
//= require autocomplete-rails
2018
//= require chosen-jquery
2119
//= require 'jsimple-star-rating.min.js'
2220
//= require pickadate/picker

app/assets/stylesheets/application.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
*= require pickadate/classic.date
1616
*= require pickadate/classic.time
1717
*= require chosen
18-
*= require jquery-ui
1918
*/
2019

2120
@import "partials/colors";

app/controllers/members_controller.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ class MembersController < ApplicationController
55
before_action :authenticate_member!, only: %i[edit step2 profile]
66
before_action :suppress_notices, only: %i[step2]
77

8-
autocomplete :skill, :name, class_name: 'ActsAsTaggableOn::Tag'
9-
108
def new
119
@page_title = 'Sign up'
1210
end

config/routes.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,6 @@
2525
resource :details, only: %i[edit update]
2626
end
2727

28-
resource :members do
29-
get :autocomplete_skill_name, on: :collection
30-
end
31-
3228
get '/profile' => 'members#profile', as: :profile
3329

3430
resources :subscriptions, only: %i[index create]

0 commit comments

Comments
 (0)