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

improve HiGlass packaging / types #702

Closed
manzt opened this issue May 22, 2022 · 2 comments
Closed

improve HiGlass packaging / types #702

manzt opened this issue May 22, 2022 · 2 comments
Labels
maintenance Related to maintenance of project

Comments

@manzt
Copy link
Member

manzt commented May 22, 2022

Motivation

HiGlass is well implemented and a core dependency of Gosling. However, it is untyped and packaged as a pre-bundled UMD JavaScript file. (pre-bundled meaning all dependencies except react, react-dom and pixi.js are included in hglib.js. This has lead to workarounds and inconsistencies in this repo, which could likely be solved all together by spending some time on improving how HiGlass is packaged.

Examples

Conclusion

I'm not sure if any of this is on the Gosling roadmap, but as we continue to add features I think it's important to consider how we could improve its foundation for greater long-term stability. We have come up with a lot of ad-hoc solutions in this repo for using higlass more like a module, but many of those solutions would be eliminated and improved if we spent some time cleaning up higlass for our use case.

@manzt manzt added enhancement New feature or request maintenance Related to maintenance of project and removed enhancement New feature or request labels May 22, 2022
@sehilyi
Copy link
Member

sehilyi commented May 23, 2022

💯 agreed.

Some additional thoughts:

  1. Another related example is that we use higlass.schema.ts which was semi-automatically generated at some point based on higlass.schema.json of the HiGlass core repo. We are using this ts file for constructing compiled HiGlass viewconfigs.

  2. Regarding the duplicated codes of data fetchers between Gosling and HiGlass, I wonder if we can find a unified method, e.g., if a new data fetcher is implemented in one library (say Gosling), the other library (i.e., HiGlass) can also use the data fetcher, and vice versa. The current challenge is due to different use cases between Gosling and HiGlass. (1) Gosling primarily uses a tabular data format to use the concept of the visualization grammar while HiGlass data fetchers use varying data formats (e.g., data generated by a vcf data-fetcher is only interpretable in an sv track). (2) HiGlass data fetchers sometimes manage the render parts as well (e.g., BAM and VCF fetchers) while Gosling data fetchers do not care about rendering.

@sehilyi
Copy link
Member

sehilyi commented Mar 7, 2025

I think we can close this issue as we are working on removing the HiGlass dependency. I linked this issue from #1113.

@sehilyi sehilyi closed this as completed Mar 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Related to maintenance of project
Projects
None yet
Development

No branches or pull requests

2 participants