Forum Discussion

nicktayl's avatar
nicktayl
Icon for Helper I rankHelper I
6 years ago
Solved

How do I port over a working d3.js visual to the visual template I initialized?

I have setup a template for a new custom visual as described here: https://www.youtube.com/watch?v=WSGimG8BRYg&t=1067s

 

Instead of creating the visual the instructor describes, I'd like to use the script for this Sankey diagram here: https://observablehq.com/d/82d202fab362a1a5

 

The purpose is to build a POC of a custom visual using existing script.

 

I am having difficulty finding instructions for a straightforward way to do this. Most tutorials focus on using the d3.js visual.

 

Much thanks!

  • Hi nicktayl,

    I have a 2-part series on porting a simple d3 example visual to custom visuals. Hopefully this may give you some ideas.

    If you have specific questions about your situation, it might we worth sharing the code you currently have and a working link to your Observable example visual - I couldn't get the link you posted to work unfortunately:

    Regards,

    Daniel

2 Replies

  • dm-p's avatar
    dm-p
    Icon for Super User rankSuper User

    Hi nicktayl,

    I have a 2-part series on porting a simple d3 example visual to custom visuals. Hopefully this may give you some ideas.

    If you have specific questions about your situation, it might we worth sharing the code you currently have and a working link to your Observable example visual - I couldn't get the link you posted to work unfortunately:

    Regards,

    Daniel

    • nicktayl's avatar
      nicktayl
      Icon for Helper I rankHelper I

      Thank you, it was the sankey diagram. Your post looks super promising. I'm surprised it didn't come up in my searches. It should be indexing high in searches. I will take a look at it before posting follow up questions. Thanks!