Disable autoformat for part of code like "<pre></pre>"

Hi,


I´m developing some RIA app in JavaScript based framework ExtJS, for wrapping up data into HTML templates are used.
They could be really complex as HTML tend to be and when CTRL + Shift + L is used to format code, all indents of tpl are lost.

Is there way how to tell PhpStorm not to format part of code? E.g. with some // <pre> markup? Double slash serves as comment so it will not breakup code and format can skip whole part between red lines.



It will make not only my life a lot easier :-) And surely force me to buy newer version as I´m using 3.x at this moment.

E.g.

Ext.define('ET.view.knowlet.ActivityStreamCommentList', {
    extend:'Ext.view.View',
    alias:['widget.knowlet', 'widget.widgetactivitystreamcommentlist'],

    border:false,

    itemSelector: '.root',
    // <pre>
    tpl:[
        '<tpl for=".">',
            '<!-- comment single -->',
            '<div >',

                '<div >',
                    '<a title="Title" href="#" >',
                        '<img alt="Alt" src="public/image/testPicture50x50.png" >',
                    '</a>',
                '</div>',

                '<div >',

                    '<h5 >',
                        '<a title="Title" href="#">{editorName}</a>',
                    '</h5>',

                    '<div >',
                        '<p>{title}</p>',
                        '<div >{createdDate:date(shareData.dateFormatLong)}</div>',
                    '</div>',

                '</div>',

            '</div>',
            '<!-- /comment single -->',
        '</tpl>'
    ]
    // </pre>
});

2 comments
Comment actions Permalink

Thanks for quick answ. Doesn´t make me happy but at least from now I know what issue ID I should follow :-)

0

Please sign in to leave a comment.