The document discusses headless Drupal, which separates the front-end interface built with JavaScript frameworks from the Drupal backend which acts as an API. It outlines the benefits of this approach, popular JavaScript frameworks that can be used including Backbone.js and AngularJS, and how to implement headless Drupal using services and REST modules in Drupal 7 and the built-in capabilities in Drupal 8. Examples are provided and it's noted that Drupal is well positioned for the growing need for APIs and data-driven approaches to websites.
2. Daniel Stout
● Madison, WI
● Web developer at Great Wolf Resorts, Inc.
● https://danielstout.com
● @danielrstout
3. What is Headless Drupal?
● Front-end: JavaScript application
● Backend: Drupal as data engine
● Bypasses Drupal theme layer
● Uses web services to get data
● Possible w/ Drupal 6 & 7,
built-in capabilities with Drupal 8
4. Benefits
● Needed when using data, not just HTML
● Allows for modern MVC JavaScript apps
● Easier to maintain, easier to debug
● Browser is the dev environment
● Easy to deploy
● Hiring for front-end? Drupal not required?
5. Client-side explosion
● Many frameworks
● Too much choice?
● # is trending downward
● Consolidation around fewer frameworks
9. Spine
● Great Wolf Resorts’ choice for MVC
● A lighter-weight, opinionated Backbone
● Single-page apps
● Written in CoffeeScript
○ Syntax similar to Ruby
● Popular with Ruby developers
● Also: Express framework with Node.js
○ Minimal framework
○ Unopinionated / Flexible
10. RESTful JSON
● Use web service to pull from Drupal
● JSON returned and ingested by JavaScript
● Great Wolf’s architecture:
○ JavaScript app makes AJAX calls
○ Room rates pulled via Aperture (Java)
to Opera Web Services (OWS)
○ Use .tpl.php only to make Views calls directly to
assemble Drupal data
12. Future & Drupal
● Data needs will increase
● Drupal 8 is well positioned
● Hybrid sites work
● Static sites still supported
● So, more data, less static