Skip to content

Commit

Permalink
track hubs build out
Browse files Browse the repository at this point in the history
  • Loading branch information
turner committed Oct 25, 2023
1 parent 27ca012 commit d1b3755
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ async function main(container, config) {
hub = await igv.Hub.loadHub(paramHash.hubURL)
trackConfigs = hub.getTrackConfigurations()
}

await initializationHelper(browser, container, trackConfigs ? Object.assign(config, { trackConfigs }) : config)
}
}
Expand Down Expand Up @@ -220,6 +220,14 @@ async function initializationHelper(browser, container, options) {
console.error(e)
AlertSingleton.present(e)
}

if (config.url && config.url.endsWith('hub.txt')) {
const hub = await igv.Hub.loadHub(config.url)
const { id } = hub.getGenomeConfig()
const trackConfigs = hub.getTrackConfigurations()
await updateTrackMenusWithTrackConfigurations(id, undefined, trackConfigs, $('#igv-app-track-dropdown-menu'))
}

}

createSessionWidgets($igvMain,
Expand Down

0 comments on commit d1b3755

Please sign in to comment.