Sha256: f1b78df80ed04936e1d53415730db1ab106a3fa4cd87a1fbbd05bb8785a066c4
Contents?: true
Size: 889 Bytes
Versions: 1
Compression:
Stored size: 889 Bytes
Contents
# SimpleAutoComplete The most simple gem for text field auto complete. You only have to specify what collection you want to use for autocompletion. ## Installation Add this line to your application's Gemfile: gem 'simple_auto_complete' And then execute: $ bundle install Add this line to application.js: //= require simple_auto_complete Add this line to application.css: *= require simple_auto_complete ## Usage Example 1: #in controller: @days = ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Satturday", "Sunday"] #in view: <%= text_field_tag_with_auto_complete :day, "", @days, id: "day_name" %> Parameters are the same like text_field_tag has, but collection parameter (@days) that is put on third position Example 2: <%= f.text_field_with_auto_complete :country, @countries, {} %>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
simple_auto_complete-0.0.1 | README.md |