Author

Upgrade Your Drupal Skills

We trained 1,000+ Drupal Developers over the last decade.

See Advanced Courses NAH, I know Enough
Nov 12 2019
Nov 12

As you know Composer is a great tool to manage packages and their dependencies in PHP, while in Drupal 8.8 is going to more composer compatible, you can find composer cheatsheet in the following.

Installing dependencies

composer install

Downloads and installs all the libraries and dependencies outlined in the composer.lock file. If the file does not exist it will look for composer.json and do the same, creating a composer.lock file.

composer install --dry-run

Simulates the install without installing anything.

This command doesn’t change any file. If composer.lock is not present, it will create it.

composer.lock should always be committed to the repository. It has all the information needed to bring the local dependencies to the last committed state. If that file is modified on the repository, you will need to run composer install again after fetching the changes to update your local dependencies to those on that file

Adding packages

composer require vendor/package 
## or in a short way
composer req vendor/package 

Adds package from vendor to composer.json’s require section and installs it

composer require vendor/package --dev

Adds package from vendor to composer.json’s require-dev section and installs it. This command changes both the composer.json and composer.lock files.

Removing packages

composer remove vendor/package

Removes vendor/package from composer.json and uninstalls it This command changes both the composer.json and composer.lock files.

 

Updating packages

composer update

Updates all packages

composer update --with-dependencies

Updates all packages and its dependencies

composer update vendor/package

Updates a certain package from vendor

 
composer update vendor/*

Updates all packages from vendor

composer update --lock

Updates composer.lock hash without updating any packages This command changes only the composer.lock file.

PS: the all above comments will work to install drupal , just keep in mind in all drupal modules,  vendor=drupal, it means if you want to install a module, just change vendor name in above command wit drupal.for example

I want to install  Nothing  module, the url of the module is https://www.drupal.org/project/nothing so the command for install it is 

composer req drupal/nothing

Development with composer and packages is much much easier than legacy code.

Additional link:

https://getcomposer.org/download/

Feb 07 2018
Feb 07

It's long time Drupal 8 has been released, it's in the middle of the way but it's going to get matured. Drupal 8.5 is going to release on  March 7, 2018. good features are going to released, significant improvements. you can the list of them Drupal Core RoadMap(8.5 + 8.6) 

Add a Layout Builder to core : it makes it very convenient to set up layouts without need add additional and config modules, Now Layout Build is on the Drupal Core and the site-builder be able to set up a default layout stack per content/entity type with his fields pre-placed. 

Drupal Layer Builder

Media initiative: Essentials - first round of improvements in core : I've remembered it was one the deficiency in Drupal 6,7  in comparison with other CMSs like Wordpress, Joomla that there was not any convenient solution in core to work with media, Drupal community released some modules to fill this deficiency but Now in Drupal 8 we have brilliant  media supporting in Drupal 8 core,new changes make it more efficient in Drupal 8.5.

Drupal 8 Media support

Introduce "outside in" quick edit pattern to core : off course Inside-Out editing is one of the coolest features of Drupal 8 for Content managers, edit the contents inline in view of your website without going far way to go to back-office content management section and finding a specific item between other contents. 

Inside out editing - inline editing in Drupal 8.5

and some other significant features are going to released in Drupal 8.5. Stay Calm Drupal 8.5 is coming. 

About Drupal Sun

Drupal Sun is an Evolving Web project. It allows you to:

  • Do full-text search on all the articles in Drupal Planet (thanks to Apache Solr)
  • Facet based on tags, author, or feed
  • Flip through articles quickly (with j/k or arrow keys) to find what you're interested in
  • View the entire article text inline, or in the context of the site where it was created

See the blog post at Evolving Web

Evolving Web