question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NeoVis.NEOVIS_ADVANCED_CONFIG is not working in react

See original GitHub issue

I wanted to change node into image as documentation here but nothing change.

here is my label config:

labels: {
        Character: {
          label: '',
          value: 'pagerank',
          group: 'community',
          size: 10,
          caption: true,
          [NeoVis.NEOVIS_ADVANCED_CONFIG]: {
            cypher: {
              value: 'MATCH (n) WHERE id(n) = $id RETURN n.size '
            },
            function: {
              title: (edge) => {
                return viz.nodeToHtml(edge, undefined);
              },
              static: {
                 font: '18px',
                 shape: true,
                 image: 'https://i.pravatar.cc/300'
              }
            }
          }
        }
      }

how does NeoVis.NEOVIS_ADVANCED_CONFIG work or what is it for?

Issue Analytics

  • State:closed
  • Created 9 months ago
  • Comments:36

github_iconTop GitHub Comments

1reaction
thebestnomcommented, Dec 14, 2022

Sorry for not answering, glad you managed

0reactions
aizaz-reactcommented, Dec 14, 2022

Hey @thebestnom thanks for the being there.

this is my new config and its working perfectly as I want.

 const config = {
      containerId: 'viz',
      neo4j: {
        serverUrl: 'bolt://3.238.37.18:7687',
        serverUser: 'neo4j',
        serverPassword: 'hate-supermarkets-grid'
      },

      initialCypher: `MATCH p = (:Character)-[:INTERACTS]->(:Character)
      RETURN p LIMIT 150
      `,

      relationships: {
        INTERACTS: {
          value: 'weight',
          caption: true
        }
      },
      labels: {
        Character: {
          label: '',
          value: 'pagerank',
          group: 'community',
          size: 10,
          caption: true,
          [NEOVIS_ADVANCED_CONFIG]: {
            static: {
              font: '18px',
              shape: 'box',
              color: '#00ff00'
            }
          }
        }
      }
    };

I’m closing this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Are the tooltips gone in 2.0.0? · Issue #176 - GitHub
Hi all, I have just tested branch 2.0.0 and noticed that tooltips are gone. Is that right? How are node properties shown?
Read more >
Neo4j NeoVis trouble - Stack Overflow
I dont get it. draw() is defined, isnt it? And the query works fine within the Neo4j-browser too. Can you figure out whats...
Read more >
Error - Unhandled promise rejection while using Neovis.js
Basically, Cannot read property 'hasChildNodes' of null, DOM is trying to get rendered before the query finishes loading the required data. I'm ...
Read more >
CDN Links - React
Both React and ReactDOM are available over a CDN. ... The versions above are only meant for development, and are not suitable for...
Read more >
NeovisConfig | neovis.js
Interface NeovisConfig ; containerId · "viz" ; serverUrl · "bolt://localhost:7687" ; serverUser · "neo4j" ; serverPassword · "sorts-swims-burglaries" ; label · "name" ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found