angular-sortable-view icon indicating copy to clipboard operation
angular-sortable-view copied to clipboard

How to install ?

Open ekarudianto opened this issue 10 years ago • 7 comments

I think it would be good if you provide the documentation to install this component since I've found nothing inside http://kamilkp.github.io/angular-sortable-view/#?tab=7 or the github page of this component it self.. or did I missed something ?

ekarudianto avatar Jun 16 '15 09:06 ekarudianto

Just include angular-sortable-view as a dependency in your angular module and use the directives explained in readme.md

kamilkp avatar Jun 16 '15 09:06 kamilkp

I see, does this component support the angular version 1.3.15 ? and also where do I get the source code ? is it in the master branch ? or other branch ? @kamilkp

ekarudianto avatar Jun 16 '15 09:06 ekarudianto

Afaik yes. Master

kamilkp avatar Jun 16 '15 10:06 kamilkp

so I've been install the component to my angularjs. The thing is, I'm using requirejs but it doesn't work, so I don't really know what I've been missing

I've include the component on my config file

here is the codes


require.config(
{
 paths: {
 angular:"path to angular",
 angular-sortable: "path to angular sortable"
            },
 shim: {
   angular-sortable:['angular'] 
 }
}
)

and I've load the component


'use strict';

define(
 [
  'angular',
  'angular-sortable'
 ], function(angular) {
   return angular.module('myApp',['angular-sortable-view']);
 }
)

this is the html structure

<div class="sortable-container" sv-root sv-part="ui.Treegrid.Options.Header.Jobs">
  <div class="well" ng-repeat="item in ui.Treegrid.Options.Header.Jobs" sv-elements="opts">
  {{item.text}}
  </div>
</div>

did I missed something ? @kamilkp

ekarudianto avatar Jun 16 '15 10:06 ekarudianto

Requirejs syntax is not supported yet. Feel free to submit a PR for that if you want.

kamilkp avatar Jun 16 '15 11:06 kamilkp

I am new to the angular, and get stuck in using your script, but your answer about including angular-sortable-view as a dependency in angular module, has answered my problems. Thanks!

BrankoIlic avatar Jul 10 '15 09:07 BrankoIlic

I totally agree. I forgot to mention it as a dependency and i wasted like 1 hour trying to figure out why it doesn't work. Thank you for the response, but you should definitely tell people in the read.me how to install it.

VanTudor avatar Jul 16 '15 13:07 VanTudor