@arnoldo.moen
In Drupal 8, you can get the block ID of a block in a few different ways. Here are a couple of options:
1
|
{{ block_id }} |
1
|
$block_id = $block->getPluginId(); |
Keep in mind that this will only work if you already have a reference to the block object. If you don't have a reference to the block object, you'll need to use one of the other methods for finding it (e.g. by using the block plugin manager or the block repository).
I hope this helps! Let me know if you have any questions.