This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 230239 - TWIG formatting
Summary: TWIG formatting
Status: RESOLVED DUPLICATE of bug 209026
Alias: None
Product: php
Classification: Unclassified
Component: Twig (show other bugs)
Version: 7.4
Hardware: PC All
: P2 normal (vote)
Assignee: Ondrej Brejla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-24 14:41 UTC by Monomachus
Modified: 2013-05-24 16:08 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Monomachus 2013-05-24 14:41:34 UTC
Please implement a better formatting of TWIG with html.

Right now if we use usual shortcut for formatting, we'll get a bad formatting because the plugin doesn't understand where the html ends and Twig starts and vice -versa.
Comment 1 mmolda 2013-05-24 16:01:55 UTC
Reproducible.

I used default layout file from Symfony 2 framework.

Twig file is formatted ok by default, but when you invoke Source->Format (or just Alt + Shift + F), all HTML elements are bad formatted.

Before format:
{% block content_header %}
    <ul id="menu">
        {% block content_header_more %}
            <li><a href="{{ path('_demo') }}">Demo Home</a></li>
        {% endblock %}
    </ul>
{% endblock %}

After format:
{% block content_header %}
<ul id="menu">
        {% block content_header_more %}
    <li><a href="{{ path('_demo') }}">Demo Home</a></li>
        {% endblock %}
</ul>
{% endblock %}
Comment 2 mmolda 2013-05-24 16:08:19 UTC

*** This bug has been marked as a duplicate of bug 209026 ***