Mathias Polligkeit created the flop library to simplify filtering, sorting, and pagination in Ecto queries. He also created flop_phoenix package with heex components. The hosts discuss Elixir docs, OTP26 bug, and introduce DNS cluster library. LS version 0.10.0 is released with new features. Dagger.io now supports Elixir. Matthias Polishkite worked on a library for cursor-based pagination. Flop library simplifies filtering, ordering, and pagination in Ecto queries. Topics include challenges of pagination, key set pagination, performance of page-based pagination, filtering in Flop, and sortable fields.
Flop is an Elixir library that simplifies filtering, ordering, and pagination in Ecto queries.
Flop allows developers to easily apply filters to Ecto queries by defining filterable fields on schemas and supporting various filter operators.
Deep dives
Flop: A powerful Elixir library for filtering, ordering, and pagination
Flop is an Elixir library designed to easily apply filtering, ordering, and pagination to ecto queries. It provides a convenient way to handle complex queries across multiple projects, saving developers from having to reimplement the same functionality. Flop allows you to define sortable and filterable fields on your ecto schemas, and provides validation and query building based on these fields. It supports both page-based and cursor-based pagination, offering flexibility based on the needs of your application. Additionally, Flop Phoenix provides Phoenix components for pagination, filtering, and ordering, making it easy to integrate with Phoenix LiveView. With its customizable features and easy-to-use API, Flop simplifies the process of filtering, ordering, and pagination in Elixir and Phoenix projects.
Applying Filters with Flop: Easy and efficient filtering for Ecto queries
Flop allows developers to easily apply filters to Ecto queries. By defining filterable fields on ecto schemas, Flop handles validation and application of filters based on provided parameters. It supports various filter operators such as equal to, greater than, less than, and more. Flop ensures that parameters are properly cast and validated, preventing errors and allowing for safe filtering. Its customizable options and integration with Phoenix LiveView make it an efficient and convenient solution for handling complex filtering requirements in Elixir projects.
Effortless Pagination with Flop: Streamlined pagination for Elixir apps
With Flop, developers can easily implement pagination in their Elixir applications. Flop supports both page-based and cursor-based pagination, offering flexibility based on the needs of the project. By defining sortable fields, Flop allows for easy sorting of query results. It also provides options for specifying default limits and customizable URL building, enabling seamless integration with URL parameters. Flop's integration with Phoenix LiveView and its compatibility with Phoenix Streams make it a powerful tool for efficient and effective pagination in Elixir apps.
Flop: A Complete Solution for Filtering, Ordering, and Pagination in Elixir
Flop is a comprehensive Elixir library that addresses the common challenges of filtering, ordering, and pagination in Ecto queries. By defining sortable and filterable fields on schemas, developers can validate and apply filters with ease. Flop supports both page-based and cursor-based pagination techniques, allowing for efficient navigation of query results. With its integration with Phoenix LiveView and seamless URL building, Flop offers a complete solution for handling complex queries in Elixir applications, alleviating the need for repetitive and error-prone code.
Most of us have created our own filtering, sorting and pagination code before in one project after the other. Mathias Polligkeit got tired of doing that too and created the flop library to wrap it all into a portable and reusable solution. We talk with Mathias to learn what it can do and are pleased to learn it's surpassed our own solutions. He also created a flop_phoenix package with heex components to help build filter forms and tables. A fun look into an interesting library!