diff --git a/docs/docs/getting-started/configuration.md b/docs/docs/getting-started/configuration.md index a10a7f66..37d89c42 100644 --- a/docs/docs/getting-started/configuration.md +++ b/docs/docs/getting-started/configuration.md @@ -23,6 +23,24 @@ Ransack.configure do |config| # This can also be configured individually in each sort link (see the README). config.hide_sort_order_indicators = true + # By default, Ransack displays sort order indicator arrows with HTML codes, but + # these can be overridden. + config.custom_arrows = { + up_arrow: '', # default: '▼' + down_arrow: 'U+02193', # default: '▲' + default_arrow: 'U+11047' # default: nil + } + + # Ransack sanitizes many values in your custom scopes into booleans. + # You can turn this off for custom scopes. + config.sanitize_custom_scope_booleans = false + + # Configure a default predicate if an unknown predicate is passed; setting it to + # e.g. 'eq' allows for allowing for exact matches by just the attribute name. + config.default_predicate = 'eq' + + # Postgres has a nulls first / nulls last option, this can be configured. + config.postgres_fields_sort_option = :nulls_first # or e.g. :nulls_always_last end ```