Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

three-forcegraph

Package Overview
Dependencies
Maintainers
1
Versions
136
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

three-forcegraph - npm Package Compare versions

Comparing version 1.6.1 to 1.7.0

example/basic/miserables.json

14

dist/three-forcegraph.common.js

@@ -7,2 +7,3 @@ 'use strict';

var tinyColor = _interopDefault(require('tinycolor2'));
require('whatwg-fetch');
var three = require('three');

@@ -14,3 +15,2 @@ var d3Force3d = require('d3-force-3d');

var Kapsule = _interopDefault(require('kapsule'));
var qwest = _interopDefault(require('qwest'));
var accessorFn = _interopDefault(require('accessor-fn'));

@@ -293,3 +293,6 @@

state.fetchingJson = true;
qwest.get(state.jsonUrl).then(function (_, json) {
fetch(state.jsonUrl).then(function (r) {
return r.json();
}).then(function (json) {
state.fetchingJson = false;

@@ -331,3 +334,8 @@ state.graphData = json;

if (customObj) {
obj = customObj.clone();
obj = customObj;
if (state.nodeThreeObject === obj) {
// clone object if it's a shared object among all nodes
obj = obj.clone();
}
} else {

@@ -334,0 +342,0 @@ // Default object (sphere mesh)

import { schemePaired } from 'd3-scale-chromatic';
import tinyColor from 'tinycolor2';
import 'whatwg-fetch';
import { Mesh, MeshLambertMaterial, BufferGeometry, BufferAttribute, Matrix4, Vector3, SphereGeometry, CylinderGeometry, Line, LineBasicMaterial, Group } from 'three';

@@ -9,3 +10,2 @@ import { forceSimulation, forceLink, forceManyBody, forceCenter } from 'd3-force-3d';

import Kapsule from 'kapsule';
import qwest from 'qwest';
import accessorFn from 'accessor-fn';

@@ -288,3 +288,6 @@

state.fetchingJson = true;
qwest.get(state.jsonUrl).then(function (_, json) {
fetch(state.jsonUrl).then(function (r) {
return r.json();
}).then(function (json) {
state.fetchingJson = false;

@@ -326,3 +329,8 @@ state.graphData = json;

if (customObj) {
obj = customObj.clone();
obj = customObj;
if (state.nodeThreeObject === obj) {
// clone object if it's a shared object among all nodes
obj = obj.clone();
}
} else {

@@ -329,0 +337,0 @@ // Default object (sphere mesh)

{
"name": "three-forcegraph",
"version": "1.6.1",
"version": "1.7.0",
"description": "Force-directed graph as a ThreeJS 3d object",

@@ -42,7 +42,7 @@ "unpkg": "dist/three-forcegraph.min.js",

"kapsule": "^1.9.0",
"ngraph.forcelayout": "^0.2.1",
"ngraph.forcelayout": "^0.5.0",
"ngraph.forcelayout3d": "^0.0.16",
"ngraph.graph": "^0.0.14",
"qwest": "^4.5.0",
"tinycolor2": "^1.4.1"
"tinycolor2": "^1.4.1",
"whatwg-fetch": "^2.0.3"
},

@@ -58,9 +58,9 @@ "peerDependencies": {

"babel-preset-env": "^1.6.1",
"rollup": "^0.56.2",
"rollup": "^0.56.5",
"rollup-plugin-babel": "^3.0.3",
"rollup-plugin-commonjs": "^8.3.0",
"rollup-plugin-node-resolve": "^3.0.3",
"rollup-plugin-commonjs": "^9.0.0",
"rollup-plugin-node-resolve": "^3.2.0",
"rollup-watch": "^4.3.1",
"uglify-js": "3.3.4"
"uglify-js": "3.3.13"
}
}

@@ -23,3 +23,6 @@ import resolve from 'rollup-plugin-node-resolve';

babel({ exclude: 'node_modules/**' })
]
],
moduleContext: {
[require.resolve('whatwg-fetch')]: 'window'
}
};

@@ -19,3 +19,6 @@ import babel from 'rollup-plugin-babel';

babel()
]
],
moduleContext: {
[require.resolve('whatwg-fetch')]: 'window'
}
};

@@ -0,1 +1,2 @@

import 'whatwg-fetch';
import {

@@ -42,3 +43,2 @@ Mesh,

import Kapsule from 'kapsule';
import qwest from 'qwest';
import accessorFn from 'accessor-fn';

@@ -236,3 +236,4 @@

state.fetchingJson = true;
qwest.get(state.jsonUrl).then((_, json) => {
fetch(state.jsonUrl).then(r => r.json()).then(json => {
state.fetchingJson = false;

@@ -272,3 +273,8 @@ state.graphData = json;

if (customObj) {
obj = customObj.clone();
obj = customObj;
if (state.nodeThreeObject === obj) {
// clone object if it's a shared object among all nodes
obj = obj.clone();
}
} else { // Default object (sphere mesh)

@@ -275,0 +281,0 @@ const val = valAccessor(node) || 1;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc