Within this dropdown, I have incorporated a checkbox containing values in the form of an object. (refer to attached image)
Every time I make a selection from the dropdown, there is a watch function that updates this new value, which is essentially an array of selected objects, and then passes it on to another object for display within a directive called "tiles".
$scope.$watch('skills', function(newVal, oldVal) {
if (newVal) {
console.log('changed!!! old value: ' + oldVal + ' new val ' + newVal);
if (newVal === undefined) {
return;
}
$scope.tiles = _.cloneDeep(newVal);
}
}, true);
angular.module('dsadad')
.component('tiles', {
templateUrl: 'tile.tpl.html',
bindings: {
tiles: '<',
onDelete: '&?'
},
controller: function ($state, _, $scope, $log, Utils, $translate, moment) {
'use strict';
var $ctrl = this;
}
});
https://i.sstatic.net/SzA74.png I am encountering a rangeError stating "Maximum call stack size exceeded."
It seems like one of the values in the array of selected objects has been mistakenly assigned as an array instead of an object, resulting in this issue.