Drupal Views: Advanced Techniques for Custom Displays and REST Exports
Views is the most used module in the Drupal ecosystem and also the most underused — most developers barely scratch the surface of what it can do programmatically.
Views is the most used module in the Drupal ecosystem and also the most underused — most developers barely scratch the surface of what it can do programmatically.
Decoupled Drupal separates the content management backend from the presentation layer. Drupal handles content modelling, editorial workflows, and permissions; Next.js handles rendering, routing, and performance. The bridge between them is Drupal's JSON:API module, which ships in core and exposes every entity type as a standardised REST API with zero configuration.
OPcache is the single most impactful PHP performance setting you can tune. Without it, PHP parses and compiles every script on every request. With a well-tuned OPcache, compiled bytecode is served from shared memory — no disk reads, no compilation.
The Migrate API is the canonical way to move data into Drupal 11 — whether that means a one-off CSV import, a recurring feed from a legacy database, or a full Drupal 7 upgrade. It implements an ETL (Extract–Transform–Load) pipeline via plugins, and every step is swappable.
Brute-force login attempts, credential stuffing, and API scraping are routine threats for any public-facing server. Nginx's built-in rate limiting module stops these attacks at the edge — before PHP even starts.
Most PHP developers know just enough about Composer autoloading to make it work. But when class resolution fails in a Drupal module, a package publishes duplicate class definitions, or a legacy library throws "class not found" mid-request, you need to understand what the autoloader is actually doing.
Drupal 11's theming system uses Twig 3, a modern templating engine that keeps logic out of templates and makes overriding core HTML straightforward. The recommended starting point is the Starterkit — a generator that scaffolds a fully functional sub-theme from Drupal core's stable base, so you own all the HTML from day one without inheriting any styles you did not choose.
Interaction to Next Paint (INP) replaced First Input Delay (FID) as a Core Web Vital in March 2024. Where FID only measured the delay before the browser started handling the first interaction, INP measures the full latency of every interaction on a page — from user input to the next visual update.
Drupal's testing infrastructure is built on PHPUnit, but it layers three distinct test types on top of it — each with different bootstrapping, speed, and fidelity trade-offs. Most Drupal developers have run tests but haven't written them deliberately.
Tree-sitter is a parser generator and incremental parsing library that gives text editors access to a concrete syntax tree of the code being edited. Emacs 29 shipped with built-in tree-sitter support, and Emacs 30 continues to expand it.