How is Drupal 8 solving it? - Drupalcamp Chattanooga 2013

bolivialodgeInternet and Web Development

Dec 14, 2013 (3 years and 10 months ago)

95 views

1
2
Joshua Taylor
, Technical Account Manager
What’s New in Drupal 8?
Keynote Address
About This Presentation
3

Aimed at technology decision makers, content authors and
typical development roles:
site builders, themers and developers.

Will provide context for major changes:

What was the problem?

How is Drupal 8 solving it?

How can I learn more?

What does it mean for me?

Will purposefully avoid getting too granular for sake of time.

Borrowing heavily from webchick’s D8 presentation, Dries’s Prague
keynote and PreviousNext’s Prague “Drupal 8 Ready” session.
Drupal 8 is still underway
, and some API changes
are still being made. Your results may vary.
4
What We’re Going to Talk About
5
Web Services
Configuration Management
Mobile
Content Authoring
“Proudly Found Elsewhere”
Better Development Practices
Multilingual
Views in Core
Theming Changes
Blocks & Layout
“Other”
6
“Proudly Found Elsewhere”
“Proudly Found Elsewhere” - Overview
7
What is the problem?
Trying to do everything ourselves holds us back, creates
“tribal knowledge” requirements for hiring, and generally
results in a lower quality product.
How is Drupal 8 solving it?
By incorporating numerous
3rd party technologies
.
Job Posting
Drupal Developer
Must have 2+ years of experience with Drupal 6/7
Some Examples

Symfony 2

Schema.org

PSR-0

Twig

PHPUnit

Guzzle

And much, much more..

We’ll be covering a lot of this later on.
8
What does this mean for..
9
Technology Decision Makers?
Easier to find qualified talent.
Site Builders, Themers & Developers?
Less time committed to learning Drupal-specific
knowledge, and more of your existing knowledge becomes
relevant to Drupal.
Job Posting
Drupal Developer
Must have 2+ years experience with OOP & MVC
How can I learn more?
10
In general, by
learning about the 3rd party technologies
that are
being incorporated.
symfony.com
schema.org
twig.sensiolabs.org
phpunit.de
guzzlephp.org
PSR-0 bit.ly/1b3NOmf
Also, this Prague session:
bit.ly/16WjdVj
11
Content Authoring
The Research
12
This is a very embarrassing
graph for Drupal.
Content Authoring - Overview
13
What is the problem?
The content authoring experience in Drupal 7 simply isn’t
on par with other competing CMS’s.
How is Drupal 8 solving it?
By adding a host of new features, including
WYSIWYG

out-of-the-box,
better authoring UI
and
in-place editing
.
New Node Add/Edit Screen
14
New Admin Toolbar & In-Place Editing
15
What does this mean for..
16
Technology Decision Makers?
Less frustration from your content authors and less time
committed to improving the authoring experience.
Content Authors?
Less frustration.
Site Builders & Developers?
Less time committed to improving the authoring
experience.
How can I learn more?
17
The best way to learn about this is to
load up Drupal 8
and
take a look. You can also
install Spark on Drupal 7
.
Spark Project
drupal.org/project/spark
Drupal 8
bit.ly/17gp8Ts
This Drupal 8 link is to dev - not alpha. I recommend dev at
this point in time.
18
Mobile
Mobile - Overview
19
What is the problem?
Drupal 7 out-of-the-box support for mobile simply isn’t
there, and that’s unacceptable given the expectation for
explosive growth in the mobile space in the near future.
How is Drupal 8 solving it?
By adding a host of new features, including
responsive

core themes,
HTML5
picture elements & new fields, a
mobile-optimized toolbar
,
improved front-end performance
,
and -
web services
(up next).
HTML5 Fields & Responsive Bartik
20
What does this mean for..
21
Technology Decision Makers?
Drupal is now much more of a “go to” solution for projects
needing mobile compatibility.
Content Authors?
Easier content authoring from mobile devices.
Themers?
More tools at your disposal for building mobile compatible
themes.
How can I learn more?
22
The best way to learn about this is to
load up Drupal 8
and
take a look. You can also
install Spark on Drupal 7
.
Spark Project
drupal.org/project/spark
Drupal 8
bit.ly/17gp8Ts
23
Web Services
Web Services - Overview
24
What is the problem?
The future of content management is agnosticism. We
want content authors to build neutral, structured content
that can be delivered across a variety of mediums. Drupal
7 assumes only one: a web page.
How is Drupal 8 solving it?
By adding built-in a
RESTful web services
, which is also
compatible with Views. It’s available with the flip of a
checkbox!
Sample Output of entity/node/1
25
Achieved strictly by
turning the module on.
What does this mean for..
26
Technology Decision Makers?
Drupal can easily be used a content management backend
for other delivery mechanisms, such as mobile apps.
Developers?
Out-of-the-box tools to provide services to other
applications.
How can I learn more?
27
Rest Module Documentation:
bit.ly/19a6u4m
This includes information about programming with the new
REST module.
PreviousNext’s “What’s New for Site Builders” Notes:
bit.ly/1fdqnLU
28
Configuration Management
Configuration Management - Overview
29
What is the problem?
Deploying new functionality across Drupal 7 site environments
is a painful process involving numerous contributed modules
and in many cases, custom development.
How is Drupal 8 solving it?
By adding a
new configuration management system based on
YAML files
. This is half of what features does - in core: the
ability to move database configuration into code. Features will
still package configuration and move it between different sites
(due to UUID, which we’ll talk about shortly).
Configuration Management - Details
30

When content types, views, vocabularies, etc.. are
created in the point-and-click interface, corresponding
YAML files are created in the active configuration
directory.

There are export/import options for this configuration.

There is a staging configuration directory where changes
can be copied to and reviewed.

There is an option to swap the staging configuration to
the active configuration.

Note that this is not a solution for content staging.
Active Config Directory & Sample YAML
31
field.field.node.body.yml
id: node.body
uuid: e11052bd-0b99-4530-b600-fbb226f4750d
status: true
langcode: en
name: body
entity_type: node
type: text_with_summary
settings: { }
module: text
active: true
locked: false
cardinality: 1
translatable: false
indexes: { }
Some API Code
Setting Values
$this->configFactory->get('my_module.settings')
->set('my_module_setting', $my_value)
->save();
Retrieving Values
$config = $this->configFactory
->get('my_module.settings');
$config->get('my_module_setting');
32
What does this mean for..
33
Technology Decision Makers & Developers?
Less time spent on deployment and deployment
processes, and more reliable deployment. More
standardization of deployment practices.
Content Authors?
Assurance that the production environment is the content
authority.
How can I learn more?
34
I’ve found the best way to learn about this is to
migrate/build
Drupal 8 modules
, which also helps introduce you to the API.
I’ll be going into a bit more detail regarding how Drupal 8
changes features in my
“And Now, for our Features
Presentation”
session.
The CMI Initiative Group
bit.ly/1b3Yh0V
The CMI Initiative Site
drupal8cmi.org
35
Multilingual
Multilingual - Overview
36
What is the problem?
Achieving multilingual on Drupal 7 is an inconsistent process
involving numerous contributed modules. Even after all that,
Drupal 7 still isn’t completely friendly for multilingual.
How is Drupal 8 solving it?
Drupal 8 is “multilingual first” -
language selection
is the first step
of installation, and English is just another language (that can be
removed).
Translation updates
can be downloaded through the
interface, and there are new methods to translate
fields and
entities
. Lastly, the number of
modules has reduced to 3
,
added to
core
, and the
UI has been improved
and made consistent.
What Multilingual Used to be Like
37
Step One of a New Drupal 8 Install
38
Bonjour!
Guten Tag!
Namaste!
Ni hao!
Hola!
What does this mean for..
39
Technology Decision Makers?
Drupal is now an excellent choice for multilingual needs.
Content Authors?
Managing multilingual content will be a much less painful,
and far more consistent process.
Site Builders & Developers?
Configuring and making multilingual available on your site
will be considerably more sane.
How can I learn more?
40
The Drupal 8 Multilingual Initiative Site:
drupal8multilingual.org
41
Views in Core
Views in Core - Overview
42
What is the problem?
Views is the number one downloaded module for Drupal 7,
and is essentially “required” to build Drupal sites. This is an
undesirable “new Drupal user” experience, and creates
confusion about what is and is not driven by Views.
How is Drupal 8 solving it?
Views is now in core.
In addition, many of the Views-suitable
interfaces in core are being replaced
with Views.
What does this mean for..
43
Technology Decision Makers?
With Views available in core, it will make it much easier for
contributed module developers to take advantage of Views
functionality without worrying about the pace of its
upgrade to Drupal 8.
Site Builders & Developers?
This seems like a given! You don’t have to download Views
anymore, and you can expect a much improved and
integrated Views experience.
44
Better Development Practices
Better Development Practices - Overview
45
What is the problem?
The development practices of
Drupal 7 are well behind modern
standards. Much like avoiding
“proudly found elsewhere”, this
also makes it more difficult to find
qualified talent.
How is Drupal 8 solving it?
In a
lot
of ways.
This is arguably the largest change in Drupal 8

(taken as a whole), so let’s dive in to a bit more detail.
Better Development Practices - Details
46

Symfony 2
- A powerful, modern, well-recognized
framework. Symfony 2 is also facilitating much of what is
follows.

OOP
- A modern development pattern that treats
components as objects, and uses techniques such as
classes, abstraction and interfaces to enforce good
development practices. All entities are now objects!

MVC
- Another modern development pattern that
provides clear separation of your model (data), views
(display) and controllers (logic).
Better Development Practices - Details
47

Routes
- A common standard for pairing requests with the
action that should be taken.

Dependency Injection
- A development pattern that helps to
produce clean, testable code.

Factories & Services
- 2 development patterns that construct/
provide objects on-demand and provide functional reusability.

Namespaces
- A development pattern that produces “virtual”
directories of code for easy referencing.

UUID
- A type of unique ID that can replace nid/uid/etc..

And much, much more..
What does this mean for..
48
Technology Decision Makers?
As with “proudly found elsewhere”, it should be much
easier to find qualified talent. In addition, modern
developers will appreciate working on Drupal more.
Developers?
More consistency in development, and the opportunity to
learn useful skills while working with Drupal, rather than
“tribal knowledge”.
How can I learn more?
49
PreviousNext’s “What’s New for Developers” Notes:
bit.ly/1fdqdEx
I am also doing a
“Saying Hello to Drupal 8”
session that
will be a primer for OOP and some of the other changes.
I’ll be showing a more-advanced-than-usual Hello, World!
module and a few other things I’ve discovered.
50
Blocks and Layout
Blocks & Layout - Overview
51
What is the problem?
Blocks are both a catch all and
bad
solution in many cases in
Drupal 7. While highly flexible from a content author’s
perspective, they are difficult to standardize, deploy and code
around.
How is Drupal 8 solving it?
Some panels-esque functionality is being built into core,
including the ability to
define layouts
using YAML/markup/
CSS. In addition,
blocks are now fieldable, revisionable
and
more
context-aware
, thanks to new “outside-in” page building
approach. The
blocks UI
has also been improved.
New Blocks Page
52
Custom Block Types
53
What does this mean for..
54
Technology Decision Makers?
Easier implementation of complex block functionality, such
as ESI (edge side includes).
Content Authors & Site Builders?
More robust block functionality, similar to what you’ve
always had with content types.
How can I learn more?
55
The SCOTCH Initiative Group:
groups.drupal.org/scotch
PreviousNext’s “What’s New for Site Builders” Notes:
bit.ly/1fdqnLU
56
Theming Changes
Theming Changes - Overview
57
What is the problem?
Theming in Drupal 7 requires some (too much) PHP and Drupal
programming knowledge, and employs some out of date javascript libraries.
How is Drupal 8 solving it?
Drupal 8 is switching to a
new theming system called Twig
, which provides
simplified syntax for output of content and execution of logic. It also
enforces strict separation of PHP and markup.
In addition,
javascript libraries have been updated
:
jQuery to 2.0
(parity with
1.9 API) and
jQuery UI to 1.1
and new libraries like
backbone.js
have been
added.
Markup has been updated to
HTML 5
.
Support for
Internet Explorer 6/7 has been dropped
.
What does this mean for..
58
Technology Decision Makers?
Happier themers, but possibly more work to support
Internet Explorer 6 and 7.
Themers?
Yay! So far, the reaction I’ve seen from themers to Twig is
very positive.
How can I learn more?
59
PreviousNext’s “What’s New for Themers” Notes:
bit.ly/1bCWnst
60
“Other”
A few more things..
61

Accessibility improvements for screen readers and
tabbing.

Lots of core modules gone.

Lots (more) contrib modules you won’t need anymore.

Form display modes.

Tour module.

Migrate module in core.

State API for local non-deployable config.

.. and more I’ve no doubt missed.
Closing Remarks
62
Drupal 8 equips the platform to be a better solution

for
the changing technology landscape.
With
improvements across the board
for a variety of roles,
our expectation is that Drupal 8 will lead to more people
contributing to Drupal than ever before.
I encourage everyone to
download and look at Drupal 8
at
your earliest opportunity.
Drupal 8 enters
final phase
of development (release blockers,
ready for module migration, upgrade path testing)
in early
2014
. Release TBD, contingent on critical bug resolution,
contributed modules, themes.
Thank you for attending!
If you have any questions about Drupal 8 or Acquia, I’m happy to stick around and
answer them.
Please provide feedback here
: http://bit.ly/1eejM0O (zero, letter O)
Resources
Dries’s Prague Keynote:
bit.ly/1agkJ5Q
The Drupal core change log:
drupal.org/list-changes
More Detailed Presentation from Drupalize.me:
bit.ly/1chJh4b
PreviousNext’s Prague “Drupal 8 Ready” Presentation:
previousnext.com.au/drupal-8-ready
For Developers
bit.ly/1fdqdEx
For Themers
bit.ly/1bCWnst
For Site Builders
bit.ly/1fdqnLU
In addition, for everything we’ve discussed, you can
set up a Drupal 8 site

yourself and have a look! bit.ly/17gp8Ts
This presentation is available on the Drupal Camp Chattanooga website.
63