-
Notifications
You must be signed in to change notification settings - Fork 152
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Typescriptify Phase IV ππΊ (#742)
* WIP on View/Tooltip TSification * Fix broken ImageSection inserting ππΊ * Completes post-inserter migration πββοΈ * PARSER! 0.2.0 π© * PARSER! 0.3.0 πͺπͺ AND all its side effects * PARSER! 0.3.1β¦0.3.2 π€Ώ + healthy refactor of renderers++ * Migrate index π§ * Long road π£ to migrating dom parser * Section + HTML parsers π΅οΈββοΈ * Text Parser migration π * Temporarily disable image section test π * Migrate parse-utils π― Co-authored-by: Tom Dale <[email protected]>
- Loading branch information
Showing
50 changed files
with
914 additions
and
637 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,7 @@ function commonPlugins() { | |
}, | ||
], | ||
}), | ||
typescript(), | ||
typescript({ noEmitOnError: false }), | ||
] | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import Section from './_section' | ||
|
||
export type Cloneable<T> = T & { | ||
clone(): Cloneable<T> | ||
} | ||
|
||
export function expectCloneable<T extends Section>(section: T): Cloneable<T> { | ||
if (!('clone' in section)) { | ||
throw new Error('Expected section to be cloneable') | ||
} | ||
|
||
return section as Cloneable<T> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.