Arunabh Das
Arunabh Das

Reputation: 14352

Meaning of double-curly double-dash in html / blade

I have a .blade.php file that was generated by Laravel and it contains the following line

{{-- --}}

What are the double-curly-double-dashes?

Is it a comment?

Upvotes: 2

Views: 896

Answers (2)

Colin Schoen
Colin Schoen

Reputation: 2592

Yes, this the syntax for a comment in the blade template. It will not be included in the HTML that is generated when the view is called.

https://laravel.com/docs/5.0/templates

Upvotes: 1

Script47
Script47

Reputation: 14530

In Blade that is a comment:

Blade also allows you to define comments in your views. However, unlike HTML comments, Blade comments are not included in the HTML returned by your application:

{{-- This comment will not be present in the rendered HTML --}}

You can use this link to find out more about Blade templating and the different type of code involved and their usage in a template file.

Upvotes: 3

Related Questions