Skip to content

Commit

Permalink
chore: fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
victorgarciaesgi committed Dec 11, 2024
1 parent c4c4c37 commit 502817b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/src/core-concepts/global-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ import { withMessage, minLength, required } from '@regle/rules';
const {useRegle: useCustomRegle} = defineRegleConfig({
rules: () => ({
required: withMessage(required, 'You need to provide a value'),
minLength: withMessage(minLength, ({ $params: [count] }) => {
return `Minimum length is ${count}. Current length: ${value?.length}`;
minLength: withMessage(minLength, ({ $value, $params: [count] }) => {
return `Minimum length is ${count}. Current length: ${$value?.length}`;
})
})
})
Expand Down

0 comments on commit 502817b

Please sign in to comment.