Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Query Laravel Package

onemustcode/query

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • API Standardization: Enables consistent query filtering, sorting, and pagination across all API endpoints, reducing ad-hoc query logic and improving maintainability.
  • Backend Efficiency: Accelerates development of internal tools or admin panels by abstracting repetitive query-building logic into reusable components.
  • Developer Productivity: Reduces boilerplate code for common query operations (e.g., filtering by ?name=John&status=active), allowing engineers to focus on business logic.
  • Build vs. Buy: Justifies a "buy" decision over custom solutions for teams already using Laravel/Eloquent or Doctrine, avoiding reinventing query parsing wheels.
  • Roadmap Alignment: Supports scaling APIs or internal tools by providing a modular, future-proof way to handle complex queries (e.g., nested filters, dynamic joins).
  • Use Cases:
    • Public APIs requiring flexible querying (e.g., e-commerce filters, search-as-you-type).
    • Internal dashboards or CRUD interfaces where users need to slice data dynamically.
    • Legacy systems migrating to Laravel where query logic is fragmented.

When to Consider This Package

  • Adopt if:
    • Your team uses Laravel/Eloquent or Doctrine and needs to standardize query parameters (e.g., ?sort=-created_at&page=2).
    • You’re building APIs or internal tools where users frequently filter/sort/paginate data.
    • You prioritize developer velocity over custom query parsing (e.g., regex, manual string splitting).
    • Your project has low-to-moderate query complexity (no advanced SQL features like raw subqueries or CTEs).
  • Look elsewhere if:
    • You need real-time query validation (e.g., rejecting invalid filter combinations) or complex nested queries (this package is lightweight).
    • Your stack is not PHP/Laravel (e.g., Node.js, Python, or raw SQL).
    • You require active maintenance (last release was 2017; fork or extend if critical).
    • You’re building a high-scale system where query performance is a bottleneck (benchmark first).
    • Your team prefers type safety (this package uses dynamic PHP; consider typed alternatives like Spatie’s Laravel Query Builder).

How to Pitch It (Stakeholders)

For Executives: "This package lets us build flexible, user-friendly APIs and internal tools faster by automating how users filter, sort, and paginate data. For example, instead of writing custom code for every ‘?status=active&page=2’ request, we’ll use a single, reusable component—saving dev time and reducing bugs. It’s a low-risk ‘buy’ for teams already using Laravel, with MIT licensing for full control. Think of it as a ‘copy-paste’ upgrade for query logic, freeing engineers to focus on core features."

For Engineering: *"The onemustcode/query package transforms messy URL params (e.g., ?sort=-price&fields=id,name) into clean Eloquent/Doctrine queries with minimal setup. Key benefits:

  • Consistency: Standardize how all APIs handle filtering/pagination.
  • Speed: Replace 50 lines of manual query logic with 2–3 lines of config.
  • Flexibility: Works for public APIs and internal tools. Tradeoff: It’s lightweight (no ORM-specific bloat) but lacks active maintenance—ideal for stable projects. We’d need to test edge cases (e.g., malformed inputs) but could extend it if needed. Alternatives like Spatie’s package are more modern but heavier."*

For Developers: *"Imagine never writing if ($request->has('sort')) { ... } again. This package parses query strings like ?name=John&sort=-created_at&page[limit]=10 into ready-to-run Eloquent queries. Perfect for:

  • Quick CRUD APIs.
  • Admin panels with dynamic tables.
  • Anywhere you’re tired of str_replace hacks for query params. Downside: It’s abandoned (last update 2017), so we’d need to vet it or fork it. But for simple use cases, it’s a godsend."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
make-dev/orca
dmstr/symfony-system-resources-bundle
dmstr/symfony-job-queue-bundle
dmstr/openapi-json-schema-bundle
dmstr/keycloak-security-bundle
dmstr/doctrine-audit-log-bundle
dmstr/api-platform-utils-bundle
dmstr/api-configuration-bundle
chrisdev/ux-components
baks-dev/finances
emuniq/filament-browser-notifications
syriable/filament-translator
hungnm28/livewire-form
wenprise/eloquent
crudly/encrypted
fadion/bouncy
cuci/prototurk-sdk
gos/pubsub-router-bundle
cuci/prototurk-sdk-symfony
clementtalleu/easyadmin-markdown-bundle