Your next Angular Query Builder ๐Ÿ

April 30, 2026 ยท View on GitHub

Your next Angular Query Builder ๐Ÿ

CI codecov npm version License: MIT

NgQubee is a query builder for Angular. Compose your API requests without re-inventing the wheel.

  • Reactive โ€” URIs emitted as RxJS observables, state held in Angular Signals
  • Pagination ready โ€” typed PaginatedCollection, fluent navigation (nextPage, lastPage, goToPage)
  • Test-driven โ€” 495+ specs
  • Multi-driver support: JSON:API, Laravel (pagination-only), Spatie Query Builder, NestJS (nestjs-paginate), PostgREST / Supabase, and Strapi

๐Ÿ“š Documentation

Full documentation lives at ng-qubee.andreatantimonaco.me โ€” driver guides, query-builder API, pagination helpers, auto-generated API reference, and version history.

This README is intentionally minimal. For everything beyond install + a five-line example, head to the docs site.

Requirements

  • Angular โ‰ฅ 16 (uses Signals)
  • RxJS ^6.5.0 || ^7.0.0

Install

npm i ng-qubee

Drivers

A driver must be specified in the configuration:

DriverBackendWire format snapshot
JSON:APIAny JSON:API-compliant backendfilter[field]=value, sort=-field, page[number]=N&page[size]=N
LaravelPlain Laravel paginationlimit=N&page=N (pagination only)
SpatieSpatie Laravel Query Builderfilter[field]=value, sort=-field
NestJSnestjs-paginatefilter.field=$op:value, sortBy=field:DESC
PostgRESTPostgREST / Supabasecol=eq.value, order=col.asc, limit=N&offset=M
StrapiStrapi v4 / v5 headless CMSfilters[field][$eq]=value, sort[0]=field:asc, pagination[page]=N&pagination[pageSize]=N

Per-driver guides โ€” wire format, supported operators, response parsing, customisation โ€” live on the docs site.

Quick start

import { bootstrapApplication } from '@angular/platform-browser';
import { DriverEnum, NgQubeeService, provideNgQubee, SortEnum } from 'ng-qubee';

bootstrapApplication(AppComponent, {
  providers: [provideNgQubee({ driver: DriverEnum.STRAPI })]
});

// In a component or service:
constructor(private _qb: NgQubeeService) {}

this._qb
  .setResource('articles')
  .addFilter('status', 'published')
  .addSort('createdAt', SortEnum.DESC)
  .setLimit(10)
  .generateUri()
  .subscribe(uri => console.log(uri));
// โ†’ /articles?filters[status][$eq]=published&sort[0]=createdAt:desc&pagination[page]=1&pagination[pageSize]=10

The full query-builder API, pagination helpers, per-driver feature matrices, and TypeScript types are documented at ng-qubee.andreatantimonaco.me.

License

MIT ยฉ Andrea Tantimonaco