-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed #20 - Could not resolve "valibot"
- Loading branch information
1 parent
28cdd5e
commit 6b8412c
Showing
9 changed files
with
20 additions
and
50 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 |
---|---|---|
@@ -1,34 +1,10 @@ | ||
import fs from 'fs-extra'; | ||
import path from 'path'; | ||
import { removeBuild, resolvePath, updatePackageJson } from '../../../scripts/build-helper.mjs'; | ||
|
||
removeBuild(import.meta.url); | ||
|
||
const { __dirname, INPUT_DIR } = resolvePath(import.meta.url); | ||
const { __dirname } = resolvePath(import.meta.url); | ||
const __root = path.resolve(__dirname, '../'); | ||
const pkg = path.resolve(__root, './package.json'); | ||
|
||
updatePackageJson(pkg); | ||
|
||
// Fill * > index.ts in subfolders | ||
let exports = [ | ||
`export interface ResolverOptions { | ||
sync?: boolean; | ||
raw?: boolean; | ||
} | ||
export interface ResolverResult<T> { | ||
values: T; | ||
errors: Record<string, any>; | ||
} | ||
` | ||
]; | ||
|
||
fs.readdirSync(path.resolve(__root, INPUT_DIR + '/resolvers'), { withFileTypes: true }) | ||
.filter((dir) => dir.isDirectory()) | ||
.forEach(({ name: folderName }) => { | ||
exports.push(`export * from '@primeuix/forms/resolvers/${folderName}';\n`); | ||
|
||
exports.length && fs.writeFileSync(path.resolve(INPUT_DIR + '/resolvers', 'index.ts'), exports.join('')); | ||
}); |
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,9 @@ | ||
export interface ResolverOptions { | ||
sync?: boolean; | ||
raw?: boolean; | ||
} | ||
|
||
export interface ResolverResult<T> { | ||
values: T; | ||
errors: Record<string, any>; | ||
} |
This file was deleted.
Oops, something went wrong.
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