I need to assign a custom extension to be recognized as a twig file in netbeans ('blade.php' as 'twig' file and give me syntax highlighting and code completion appropriately). The problem with using the File association option (in Tools > Options > Miscellaneous > Files
)
is that it won't let me add '.' in extension like blade.php, it works with single worded extensions like php, html, css etc.
Will be grateful if anybody can help me with this!
Workaround I figured out and seems to work (at least Netbeans 8.x+)
Tools > Options > Miscellaneous > Files
Associate File Type (MIME)
select TWIG (text/x-twig)
Options
window%AppData%\Netbeans\<version>\
config\Services\MIMEResolver
user-defined-mime-resolver.xml
<ext name="blade"/>
entry (or whatever you entred above)Voilà, higlighting should now work in Netbeans IDE :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With