Skip to content

Commit

Permalink
Merge pull request #596 from darrylnoakes/fix/factory-function-exports
Browse files Browse the repository at this point in the history
fix(chord-symbol): export TypeScript types for parser and renderer factory functions
  • Loading branch information
no-chris committed Jan 26, 2023
2 parents 303e18a + f2711d4 commit 29b83bf
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions packages/chord-symbol/types/index.d.ts
@@ -1,12 +1,12 @@
export {
chordParserFactory,
chordRendererFactory,
Chord,
ChordInput,
FormattedChord,
NormalizedChord,
ParserConfiguration,
RendererConfiguration,
chordParserFactory,
chordRendererFactory,
};

/**
Expand Down Expand Up @@ -269,3 +269,17 @@ type RendererConfiguration = {
* Don't do that!
*/
type customFilter = (arg0: Chord) => Chord;

/**
* Create a chord parser function.
*/
declare function chordParserFactory(
configuration?: ParserConfiguration
): (input: string) => Chord;

/**
* Create a chord rendering function.
*/
declare function chordRendererFactory(
configuration?: RendererConfiguration
): (chord: Chord) => string;

0 comments on commit 29b83bf

Please sign in to comment.