Skip to content

Re-implement Gosling API functions in v2 #1161

@sehilyi

Description

@sehilyi

API functions are entirely unimplemented in the v2 branch. An example function is zoomTo, which navigates to a specific genomic range from the JS side. It looks like implementing the missing API functions seems to be the main thing left for releasing v2.

The complete list of API functions defined in v1 can be found in createApi().

export function createApi(

The API functions need to be implemented in this new createAPIV2() function:

// TODO: After fully implementing this, remove `Partial` from the return type
export function createApiV2(): Pick<GoslingApi, 'subscribe' | 'unsubscribe'> & Partial<GoslingApi> {
return {
subscribe,
unsubscribe
};
}

API Functions to Implement

Subscribing Events

  • subscribe
  • unsubscribe

Exporting Images

  • getCanvas
  • exportPng
  • exportPdf

Zoom (#1165)

  • zoomTo
  • zoomToExtent
  • zoomToGene
  • suggestGene

Retrieving Track/View Information

  • getTrackIds
  • getTracksAndViews
  • getTracks
  • getTrack
  • getViews
  • getView

Sub-issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestv2Issues related to Gosling v2

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions