library(tidygraph)
#> 
#> Attaching package: 'tidygraph'
#> The following object is masked from 'package:stats':
#> 
#>     filter
play_geometry(10, 3) %>%
  morph(to_shortest_path, from = 1, to = 2:10) %>%
  crystallize() %>%
  pull()
#> [[1]]
#> # A tbl_graph: 2 nodes and 1 edges
#> #
#> # An undirected simple graph with 1 component
#> #
#> # Node Data: 2 x 3 (active)
#>        x     y .tidygraph_node_index
#>    <dbl> <dbl>                 <int>
#> 1 0.0952 0.307                     1
#> 2 0.146  0.651                     2
#> #
#> # Edge Data: 1 x 3
#>    from    to .tidygraph_edge_index
#>   <int> <int>                 <int>
#> 1     1     2                     1

Created on 2018-12-08 by the reprex package (v0.2.1.9000)