Skip to content

Commit

Permalink
Add IInputs interface and refactor run function to use it
Browse files Browse the repository at this point in the history
  • Loading branch information
harrymaynard committed Feb 8, 2025
1 parent 2ac343a commit 90a543a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 130 deletions.
116 changes: 0 additions & 116 deletions action.ts

This file was deleted.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions src/interfaces/IInputs.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
export interface IInputs {
markdownFiles: string
title: string
author: string
publisher: string
cover: string
version: string
lang: string
tocTitle: string
hideToC: string
output: string
}
14 changes: 1 addition & 13 deletions src/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,7 @@ import { glob } from 'glob'
import epub from 'epub-gen-memory'
import matter from 'gray-matter'
import { type IChapter } from './interfaces/IChapter'

interface IInputs {
markdownFiles: string
title: string
author: string
publisher: string
cover: string
version: string
lang: string
tocTitle: string
hideToC: string
output: string
}
import { type IInputs } from './interfaces/IInputs'

// eslint-disable-next-line @typescript-eslint/require-await
export const run = async (inputs: IInputs): Promise<void> => {
Expand Down

0 comments on commit 90a543a

Please sign in to comment.