"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.getDegree = void 0;

var getDegree = function getDegree(node, edges) {
  var nodeId = node.data.id;
  var index = 0;
  edges.forEach(function (edge) {
    if (edge.data.source === nodeId || edge.data.target === nodeId) {
      index = index + 1;
    }
  });
  return index;
};

exports.getDegree = getDegree;