-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(#285): propValidator => makeProps
Unfortunately, the makeProps type hints only work for some types in Vue, others somehow get resolved to any. As far as I can tell, this is due to PropType<> being buggy. I also tested @vue/composition-api@1.1.5 and PropType does appear to be broken there as well. Let’s hope that one day Vue will properly support this.
- Loading branch information
1 parent
930eb2b
commit 37d0a51
Showing
14 changed files
with
228 additions
and
248 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
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
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
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 |
---|---|---|
@@ -1,12 +1,10 @@ | ||
import { z } from 'zod' | ||
|
||
import { SpecifyRequiredProps } from '../types/utilities' | ||
|
||
export namespace KottiLine { | ||
export const propsInternalSchema = z.object({ | ||
text: z.string(), | ||
export const propsSchema = z.object({ | ||
text: z.string().nullable().default(null), | ||
}) | ||
export type PropsInternal = z.infer<typeof propsInternalSchema> | ||
|
||
export type Props = SpecifyRequiredProps<PropsInternal, never> | ||
export type PropsInternal = z.output<typeof propsSchema> | ||
export type Props = z.input<typeof propsSchema> | ||
} |
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
Oops, something went wrong.