marcoslin / angularAMD

Facilitate use of RequireJS in AngularJS
http://marcoslin.github.io/angularAMD
MIT License
734 stars 171 forks source link

ng-controller in index.html not working #183

Closed kudeshiyah closed 6 years ago

kudeshiyah commented 7 years ago

ng-controller on index.html outside ng-view is not working. i also followed your plunker ( http://plnkr.co/edit/azsKJnFJ0pYwBW0dGMFH?p=preview ) for this issue but that is not working either it seems it is very old. plz help

sushant1221 commented 6 years ago

In the plunker there was issue with plugin link itself. Replace main.js with this and you are good to go.

require.config({

  baseUrl: "js/scripts",

  // alias libraries paths.  Must set 'angular'
  paths: {
    'angular': '//ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular.min',
    'angular-route': '//ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular-route.min',
    'angularAMD': '//rawgit.com/marcoslin/bower-angularAMD/v0.1.0/angularAMD.min'
  },

  // Add angular modules that does not support AMD out of the box, put it in a shim
  shim: {
    'angularAMD': ['angular'],
    'angular-route': ['angular']
  },

  // kick start application
  deps: ['app']
});

Good luck.

@marcoslin I think this issue can be closed.

kudeshiyah commented 6 years ago

Thanks for your reply, but know we have moved our platform to angular4. closing the issue