Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add igv component #537

Merged
merged 15 commits into from
Jan 28, 2021
Merged

Add igv component #537

merged 15 commits into from
Jan 28, 2021

Conversation

HammadTheOne
Copy link
Contributor

Closes plotly/dash-core#250

About

  • I am closing an issue
  • This is a new component

Description of changes

This PR is a continuation of the draft PR created by @shday here. This PR includes the following additions to the original PR:

  • Updates to igv.react.js to enable async loading of the component and greatly reduce bundle size.
  • Fixes to enable passing of properties through a Dash app by removing and then re-rendering the IGV browser upon component change.
  • Renaming and fixing of tests to allow them to work with local datasets with app.get_asset_url to pass a URL directly to the IGV browser.
  • Added a simple demo app to showcase some features and test prop changes.
  • Changed igv package from experimental react fork to (now react) compatible master fork.

@HammadTheOne HammadTheOne mentioned this pull request Jan 13, 2021
Closed
2 tasks
@jackparmer
Copy link
Contributor

When you add docs for this, can you please also add docs for dash-ngl at the same time, since it never got documented over at https://dash.plotly.com/dash-bio

package.json Outdated Show resolved Hide resolved
*/
export default class Igv extends Component {
componentDidMount() {
var igvContainer = document.getElementById(this.props.id);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't use getElementById - use a ref instead. For an example, see https://github.com/plotly/dash-core-components/pull/604/files where this change was made to dcc.Graph

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in 0e650d0.

Copy link
Collaborator

@alexcjohnson alexcjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Beautiful! 💃 once tests pass (looks like just a minor lint issue)

@HammadTheOne HammadTheOne merged commit d5e521a into master Jan 28, 2021
@HammadTheOne HammadTheOne deleted the add-igv branch January 28, 2021 18:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants