Twig Components / Methods / format_file
Note: You are currently reading the documentation for Bolt 5.0. Looking for the documentation for Bolt 5.2 instead?
format_file(line, text = null) is a Twig filter to generate the file path inside an <a> element. If the path is
inside the kernel root directory, the kernel root directory path is replaced by kernel.project_dir (showing the full
path in a tooltip on hover).
file
type: string
line
type: integer
text (optional)
type: string default: null
Source: Twig
                    
                        
                            
                        
                        Edit this page on GitHub
                    
                                        
Couldn't find what you were looking for? We are happy to help you in the forum, on Slack or on Github.
                
            Couldn't find what you were looking for? We are happy to help you in the forum, on Slack or on Github.