Blade engine: print triple curly braces

前端 未结 5 2081
灰色年华
灰色年华 2020-12-11 01:25

I know how to print double curly braces in Laravel: @{{ }}.

But how can I print triple curly braces? My first thought of adding an @ before does not wor

5条回答
  •  余生分开走
    2020-12-11 01:45

    Update

    Very recently, a pull request was merged that fixes this problem!!
    As of Laravel 5.1.7 it is possible to use the @ sign as expected:

    @{{{ ... }}}
    

    Original Answer

    The least ugly workaround I found up until now is to escape the first two brackets as normal and adding an invisible between them and the third bracket:

    @{{‌{test}}}
    

    I'll investigate further and update this answer if I find something better...

提交回复
热议问题