drupal Create a content entity using Drupal Console


Example

Drupal console brings scaffolding to the Drupal ecosystem and makes it easy to generate a content entity.

In most instances you will find it easier to work with a custom entity within a custom module.

Step 1 : Generate a module

vendor/bin/drupal generate:module

Follow the prompts and create your custom module.

Step 2: Generate a content entity

vendor/bin/drupal generate:entity:content

Follow the prompts on your commandline making sure to select the custom module created in the previous step.