On Github socketwench / handsOnD8SiteBuilder
Flag
Flag Friend
Examples
(We're hiring!)
I work as a developer with Blink Reaction. We're soon to be the world's largest Drupal Development Consultancy. We're hiring! You can talk to me after the session, tell me about your project, or talk to anyone at the booth outside.http://socketwench.github.io/handsOnD8SiteBuilder
(If you're a site builder)
Users and Permissions
Structuring Content
Modules
Views in core
Better, out-of-the-box i18n Support
(Fewer modules to install, yay!)
Writing modules
Writing themes
Upgrading core and modules
Deploying Configuration
Local installation
Virtualization
Hosting Providers
Install a webserver on your laptop
And many others...
https://www.drupal.org/project/drupal
https://www.acquia.com/downloads
Free for 3 dev sites
http://getpantheon.com/d8
Prettier & handles languages better
Asks similar questions as in 7.x
Hosting providers may do this for you!
Pair up!
If neither of you have a web server installed, choose a hosting provider
Install the latest Drupal 8 Beta
Saves configuration to code
Works okay in Drupal 7
Administrator-built structures
Administrator-built structures
Administrator-built structures
Administrator-built structures
User created & instantiated objects
User created & instantiated objects
User created & instantiated objects
User created & instantiated objects
Admin > Development > Configuration Management
Creates a *.tar.gz of all site configurations
Easiest way to get export filnames
Create a new content (node) type
Export your new content type
Make changes to your content type
Export your content type again, what changed?
Tied to their owning entity type
entity_type/field_nameNo longer sharable between entity types (node, user)
Sharable between bundles (article, story)
Comments
Entity Reference
Link
Date
Telephone
Not a module, not a Wordpress "Plugin"
Programming pattern -- Object-oriented info hook
And many others...
Exportable to *.yml
Migrated from site to site
Create a new field for your content type
Re-export your content type, did anything change?
Explore the export interface, find two places to export your field
Admin > People
Superuser account created on install
No real changes here
Admin > Configure > People > Account Settings
Welcome messages, email prefs, field management
Pretty much as you expect
New in 8
Control order of fields on user edit form
Stored as simple config
Create a new user
Create a custom field for the user, export it
Answer: Are users content or config?
Answer: How many exports are needed to capture account customizations?
And is it still the same?
administer flags: title: 'Administer Flags' decription: 'Define and manage Flags and Flag settings.' restrict access: TRUE permission_callbacks: - Drupal\flag\FlagPermissions::permissions
Admin > People > "Roles" tab
Roles are now config entities
No UI changes from 7.x
Admin > People > "Permissions" tab
Set checkbox = Grants permission
Clear checkbox = Doesn't grant, doesn't deny
Exportable, Migratable
Create a "content editor" role
Assign it node creation/editing rights
Answer: How do you export permissions?
No more waiting to build real sites
Largely unchanged from 7.x
Core's own UI uses views
Makes modifying core pages easy and safe
Exportable, migratable
Uses core's main export UI, not Views UI
Create demo content using your new content type
Beginners: Create a new view for your content type
Modify one of core's default views
Export the view configuration
You'll need less of them for a functional site
Vastly different programming makes porting difficult
Installation and config management is different
No built-in FTP downloader
Use drush 7.x or download manually
Please use version control
Many hosting providers have it baked in
Many hosting providers have it baked in
Many hosting providers have it baked in
Yeah, it's the opposite of 7.x
core/ directory makes upgrading easier
There is no sites/all directory
Not really possible
Create new instance, select module to install
Click "SFTP" in your dashboard
Use your favorite SFTP client
Any properly designed module will have exportable config
Saving directly to database tables is strongly discouraged
Often exported from Drupal itself
Makes creating "features" modules easy!
https://www.drupal.org/project/flag
Download the 8.x-4.x-dev version
Download and install Flag module
Create a new Flag: Admin > Structure > Flags
Export your new Flag
Install manually or with drush
It's the opposite of 7.x, but...
...it's much easier to find.
Well, lots, actually.
Replaces PHPtemplate
Common outside of Drupal
Fast; compiles down to PHP
http://twig.sensiolabs.org/documentation
https://www.drupal.org/theme-guide/8
Latest JQuery and Backbone.js
Accessible and responsive
No Features required!
name: My Blog type: module description: My Awesome Blog Feature core: 8.x package: Features dependencies: - link
Required, even if empty
Filenames are significant!
Much easier to build, then export
Node type ID, field ID, etc.
Start with the biggest piece, and look for dependencies
uuid: 88ba4ba6-2694-4154-9048-72fb7fdb4e4c langcode: en status: true dependencies: config: - field.storage.node.field_see_also - node.type.blog module: - link id: node.blog.field_see_also field_name: field_see_also entity_type: node bundle: blog label: 'See also'
Each configuration assigned a UUID
Remove if you need unique IDs between dev/test/prod
uuid: cf4c20f8-213a-46fc-8a06-6f1036203231 langcode: en status: true dependencies: module: - menu_ui third_party_settings: menu_ui: available_menus: - main parent: 'main:' name: Blog type: blog description: '' help: '' new_revision: false preview_mode: 1 display_submitted: true
Will halt module enabling
Error message will identify missing configuration
Perform a full export
Build a new feature module based on your custom content type
Delete your custom configuration
Upload and enable your custom module
Learn and contribute to Drupal Core
Mentors will help you setup and find issues
9am - 4pm on the FTC Campus
@socketwench
http://socketwench.github.io/handsOnD8SiteBuilder