ExLibrisGroup / primo-explore-devenv

A node.js , gulp based development enviornment for Primo's new UI customizations (css,images,html and javascript)
BSD 3-Clause "New" or "Revised" License
114 stars 84 forks source link

Question - how to load with debug info by default #130

Closed danizen closed 2 years ago

danizen commented 3 years ago

With the following in custom.js, I can see the word Hello, Get It and select the prm-opac-after element easily. But although it has a scope containing a message, I cannot access its scope.

I define the code as follows:

app.controller('OpacAfterController', 
  [ '$scope',
  function($scope) {
      $scope.greeting = 'Hello, Get It';
    },
]);

app.component('prmOpacAfter', {
  bindings: { parentCtrl: '<'},
  controller: 'OpacAfterController',
  template: '<div class="fubar">{{ greeting }}</div>',  
});

I see the message "Hello, Get It" and can inspect and then move up to the wrapping element prm-opac-after.

However, the following does not work, in that I cannot see the variable greeting in the scope, nor really interact with the controller meaningfully.

console-debugging

I know this is an AngularJS questions and not a primo-explore-devenv question, but I need to get some traction so that I can make progress.

danizen commented 3 years ago

Is there anyway to set this up so that I do not have to run:

angular.reloadWithDebugInfo()

When I am running against PrimoVE directly, it makes sense to need to reloadWithDebugInfo, when running via gulp and proxy, it would make sense to already be in debug mode.

danizen commented 3 years ago

I will only leave this open for a day or so.