Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Drupal 8 overview

Drupal 8 overview

Quickly hacked the "offical" Drupal 8 Preview Slideshow to keep a session to my co-workers at Integral Vision. Heavily used Schnitzel's DCBarcelona Drupal 8 experience session record too. Thanks to all!

Tamás Hajas

October 07, 2015

Transcript

65 slides
  1. More info Installing and Choosing Modules for Multilingual in Drupal

    8 https://www.drupal.org/node/2415945 Multilingual demo install https://www.drupal.org/project/multilingual_demo Workshop video http://www.drupal8multilingual.org/workshop Initiative site http://www.drupal8multilingual.org/
  2. Twig Example: node.html.twig <article{{ attributes }}> {{ title_prefix }} {%

    if not page %} <h2{{ title_attributes }}> <a href="{{ url }}" rel="bookmark">{{ label }}</a> </h2> {% endif %} {{ title_suffix }} {% if display_submitted %} <footer class="node__meta"> {{ author_picture }} <div class="node__submitted {{ author_attributes.class }}"{{ author_attributes| without('class') }}> {% trans %}Submitted by {{ author_name|passthrough }} on {{ date }}{% endtrans %} {{ metadata }} </div> </footer> {% endif %} <div class="node__content {{ content_attributes.class }}"{{ content_attributes| without('class') }}> {{ content|without('links') }} </div> {% if content.links %} <div class="node__links"> {{ content.links }} </div> {% endif %} </article> 1. HTML5 tags 2. {{ print a variable }} 3. {% logic(stuff) %}
  3. Twig blocks & extends Twig Blocks are not Drupal Blocks!

    {# Extending the page template to override the title #} {% extends 'themes/THEMENAME/templates/page.html.twig' %} {% block title %} Nice New Title for the whole world to see. {% endblock %} https://www.newmediadenver.com/blog/twig-extending-templates
  4. CSS is SMACS & BEM based #id not used (for

    styling) / removed 90% of the div removed libs (eg. jQuery) aren’t loaded by default better accessibility
  5. More info Theming session in DCBarcelona by mortendk https://events.drupal.org/barcelona2015/sessions/drupal-8-theming-0 Backend

    of the front-end (DCBarcelona, laurii) https://events.drupal.org/barcelona2015/sessions/drupal-8-theme-system http://drupal.org/theme-guide/8 drupal.org/coding-standards/css
  6. Configuration management in Drupal 8 (Drupalaton 2013) https://videotorium.hu/hu/recordings/details/ 6837,Configuration_management_in_Drupal_8 Configuration

    management in Drupal 8 (Drupalaton 2015) https://www.youtube.com/watch? v=OVFQDdTRCeM&list=PLB89p5xo_6ST7DM69sJVEPRIA9hrS6h2- &index=5 http://nuvole.org/blog/2015/aug/10/drupal-8-configuration-management- beware-pitfalls More info
  7. Features? “In Drupal 8, Features will return to it's original

    mission of bundling functionality rather than just managing configuration.” – M. Potter, Features maintainer https://events.drupal.org/barcelona2015/sessions/features-drupal-8
  8. Not invented here 
 "Proudly Found Elsewhere" Much more modern,

    object-oriented code (classes, inheritance, interfaces, etc.) Embracing latest PHP standards (e.g. PSR-4*, namespaces, traits) Using many “best of breed” external libraries: Composer, PHPUnit, Guzzle, Zend Feed Component… Non-Drupal developers can start work right away * http://www.php-fig.org/psr/psr-4/
  9. Plugin System Bart Feenstra: The Drupal 8 plugin system: extensibility

    for all https://www.youtube.com/watch? v=IoxEtvydKuc&list=PLB89p5xo_6ST7DM69sJVEPRIA9hrS6h2-&index=7 Drupal 8 Plugin Deep Dive (DCBarcelona) https://events.drupal.org/barcelona2015/sessions/drupal-8-plugin-deep-dive
  10. Web services other systems or framewor ks desktop Android applicati

    ons other Drupal sites Flash compone nts iPhone applicati ons kiosk applicati
  11. GETting data into Drupal: Guzzle $client = \Drupal::httpClient(); $config =

    \Drupal::config('3rdparty.settings'); // Format arguments for passing in URL. $arg = urlencode($argument); // Pull data from 3rd party's REST API. $api_key = $config->get('api_key'); $request = $client->get("http://3rdparty.com/ $arg/?key=$api_key"); // Get the response and do something with it. $response = $request->send(); $json = $response->json(); ...
  12. Performance Making Drupal fly - The fastest Drupal ever is

    here! https://events.drupal.org/barcelona2015/sessions/making-drupal-fly-fastest-drupal-ever-here The future of decoupled Drupal http://buytaert.net/the-future-of-decoupled-drupal https://www.youtube.com/watch?t=41&v=JwzX0Qv6u3A BigPipe Smart Caching
  13. What about the upgrade path? Instead of an upgrade path,

    Drupal 8 have a migration path! Some Drupal 6 migrations already in core, more in the works, see https:// groups.drupal.org/imp https://dev.acquia.com/blog/seamless- migration-drupal-8-make-it-yours
  14. What’s this 8.0.0 talk? Drupal 8 will use semantic versioning

    Drupal 8.1.0 will include new features and/or APIs New releases will be (mostly) backwards compatible New 8.x releases every 6 months (planned) No need to wait years for new things Bugfixes in minor releases, eg. 8.1.5
  15. What about contributed modules? Check status of contrib module upgrades

    at: drupal.org/project/contrib_tracker To avoid upgrade pain, stick to well-vetted contributed modules over custom code. Other tips: www.acquia.com/blog/getting-your- site-ready-drupal-8
  16. And my own modules? To start the upgrade of you

    own code, use drupal.org/project/drupalmoduleupgrader If you need to or want to start your module fresh, see drupal.org/project/console Creating Drupal 8.x modules https://www.drupal.org/node/1915030

More Decks by Tamás Hajas

Other Decks in Technology