Skip to content

Expose Tram-One type interfaces #199

@JRJurman

Description

@JRJurman

Summary

In the following example, it's not possible to define a strict type for ref, since we don't explicitly export TramOneHTMLElement.

const notesRef = useStore<{ ref: any }>({ ref: null });
useEffect((ref) => {
  notesRef.ref = ref;
});

Ideally we'd like to do the following:

const notesRef = useStore<{ ref: TramOneHTMLElement | null }>({ ref: null });

We should look into how we can expose this interface in a way that consumers can easily import these types. We should probably also update the website to reflect the exposed types.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions