angularjs-eclipse icon indicating copy to clipboard operation
angularjs-eclipse copied to clipboard

HTML Formatter for unknown tags

Open didlich opened this issue 11 years ago • 10 comments

Hi, nice and helpful plugin. One thing was always annoying: HTML formatting of angular element directives. The default WTP HTML formatter put them in one line.

There are plugins, which solve this, like shown here:

http://www.anagram.at/show/category/knowledge-transfer/

but then angular features, like navigation feature, are not available any more

Is there a way to include the formatter feature for your angular plugin???

didlich avatar Oct 12 '14 11:10 didlich

AngularJS Eclipse is based on WTP HTML editor. Is there is a problem with standard HTML tags?

If yes, I suggest you to post your requirement on WTP bugzilla, otheriwse If it works with snardard HTML tags but not with anugular element, I will study if it's possible to contribute to WTP formatter to manage angular element.

angelozerr avatar Oct 12 '14 15:10 angelozerr

There is no problem with standard HTML tags, the formatter behaves as expected in this case. There seems to be several bug reports in WTP in this direction, but they are not fixed yet

didlich avatar Oct 13 '14 18:10 didlich

Ok, could you give me a simply sample with angular + html elements which causes problem. Thank's.

angelozerr avatar Oct 14 '14 07:10 angelozerr

Yes, sure. This is a template from the Ionic-Framework with angular directives: see also examples page: http://codepen.io/ionic/public-list/

<ion-view>
  <ion-nav-buttons side="right">
    <a class="button button-icon icon ion-plus" ng-click="newItem()">
    </a>
  </ion-nav-buttons>

  <ion-content class="has-header">
    <ion-list>
      <ion-item ng-repeat="item in items">
        {{item.name}}
      </ion-item>
    </ion-list>
  </ion-content>
</ion-view>

didlich avatar Oct 14 '14 09:10 didlich

thank's @didlich for your sample.

@vrubezhny do you know how to extend WTP HTML formatter to fix this issue? Thank's!

angelozerr avatar Oct 14 '14 22:10 angelozerr

+1 That feature would be really awesome!!

michael-wirth avatar May 02 '15 14:05 michael-wirth

I don't know how to do that. @vrubezhny have you an idea?

angelozerr avatar May 02 '15 21:05 angelozerr

No idea on how WTP HTML formatting works, but this could be another issue we should contribute to. (the first one I mean is contributing to the validation). Need some time to investigate...

But anyway, imho, it's better to create a BugZilla for the issue (or update a recent existing one) with description and example of how it works, what's wrong with it and how it should work. So WTP Source Editing committers could take a look at the problem having a good example.

vrubezhny avatar May 05 '15 00:05 vrubezhny

+1

maxiplay avatar Sep 29 '15 17:09 maxiplay

+1

mostafabarmshory avatar Jul 15 '16 04:07 mostafabarmshory