Skip to content

Conversation

chestergalindo
Copy link
Contributor

  • Review API page, translate and little fix to spanish

@vercel
Copy link

vercel bot commented Jun 30, 2020

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/bluebill1049/react-hook-form-website/df6lgxzmu
✅ Preview: https://react-hook-form-website-git-fork-chestergalindo-v6.bluebill1049.vercel.app

@bluebill1049
Copy link
Member

Thank you very much @chestergalindo ❤️

@bluebill1049 bluebill1049 merged commit 680372c into react-hook-form:V6 Jun 30, 2020
bluebill1049 added a commit that referenced this pull request Jul 1, 2020
* set up v5 fundation

* fix the build

* get both v5 and v6 running

* clean up v5/v6 docs

* update on v6 on api page

* more v6 clean up

* more page update

* update valdiation resolver

* update react-hook-form-devtools

* fix ts page

* fix path

* fix path

* fix path

* Insert 'clearError' method (#253)

I've found 'clearError' missed in the example code and i inserted it.

* Update setError.ts

* more update on V6

* update

* update on formContext

* fix link

* remove extra line

* update yarn.lock

* update useform content

* include useWatch

* useWatch other lang

* update docs around resolver

* pretiter

* update package version

* animation on side nav bar

* include migration guide page

* fix lang selection

* update nav url

* working on the TS page

* try to fix css module with ts

* update all the page with location

* update doc for formstate

* move schema validation to get started page

* update resolver doc on get started

* update migration guide with dirty/dirtyFields

* update resolver supports

* update resolver docs

* update resource with animation

* update CSB for get started page

* update resolver example

* update codesandboxs

* fix apiPage all codesandbox

* include exported TS type

* update package location

* Update DevTools.tsx

* update sub title

* translating migration v5 to v6 page to pt (#267)

* update spansih migration guide

* get migration guide ready

* update packages

* watching input change section

* content update

* fix style

* indicate lib package size

* update doc on useFieldArray

* include another video from japanese

* working animmation

* working animation

* refine animation

* sort out animation order

* improve animation code

* fix animation sequence

* include shouldFocus prop

* error messaage component

* update on TS page

* include description for all types

* include animation for migrate guide

* fix home page animation

* rename OnSubmit to SubmitHandler

* complete watch section at home page

* Improved ApiPage bundle size (#278)

* Fixed typo (#273)

* Fixed FormContext Performance code (#274)

* Link from Controller -> rules to register (#271)

* Translated  advanced useage page into jp (#277)

* Fixed APIPage link (#276)

* Improved ApiPage bundle size

Co-authored-by: Dan Dascalescu <ddascalescu+github@gmail.com>

* Fixed path (#279)

* Fixed ApiPageV5 (#280)

* Improved FaqPage perf (#281)

* Split the bundle on each page (#282)

* Fixed AdvancedPage

* Fixed GetStartedPage

* Removed unused files

* Improved performance DevTool page (#283)

* Split bundle DevTool page

* Fixed props variables name

* fix bugs (#285)

* fix error message type and update for v6 (#284)

* fix error message type

* fix error message type

* add ErrorMessageV5 component

* fix build

* close #1749 around controller rules update

* fix build

* prepare ts pages ready for other langs

* Correct V5 & V6 Docs + added ts-codesandbox (#289)

* Feature/ts codesandbox (#290)

* Store DefaultValues Code Example Properly

* The yup schema in codesandbox was missing lastName

* Add a ts ValidationResolver

* the Joi Resolver was Showing No Error below input

* Add ts joiResolver

* translate content for ts page

* include controller api update

* update more examples

* update example for codesandbox

* update conditional input

* update order

* fix home page contrast with light mode

* close #286 issue around dirty file

* close #250 around inital render with defaultValues

* include example for modal

* translate other lang

* Feature/ts codesandbox (#291)

* Correct to be ready when v6 arrives

* Fix ApiV5 imports

* Add unregisterCode js & ts example

* update to submitFocusError

* fix sentence for resolver

* include shouldUnregister

* fix translation with unregister and fix some russian translation

* update with error message with @hookform

* update home page panel

* update packages

* update doc for controller

* update on get started page

* fix get started page

* imporve getValues doc

* update getvalues for all and get translated tmr

* include videos links for section

* fix style

* translate getValues api

* update doc

* update doc

* Feature/get started example update (#296)

* Update Code-examples for get-started API

* Update base js example

* Add TS example for register Code + codesandbox

* Add a yarn install vs. npm

* Add validation ts and code-examples

* Update src/components/GetStarted.tsx

Co-authored-by: Bill <bluebill1049@hotmail.com>

* remove extra install

* more doc update

* revert a CSB

* more doc update

* update on resource page

* update get started page

* include migration guide for error message

* clean up advance page

* change all alert to console

* update resource page style

* fix api and footer

* fix link nav

* include info about react native testing

* close #1868 useFieldArray doesn't support conditional render

* update error message size

* update with videos

* Feature/get-started-example-update (#298)

* Update Code-examples for get-started API

* Update base js example

* Add TS example for register Code + codesandbox

* Add a yarn install vs. npm

* Add Migrate Code Example Ts and CodeSandbox

* Do Some Linting and add ts + CodeSandbox

* Add useEffect ui library effect

* Undo some changes to follow BlueBill's Pattern

* Update src/components/GetStarted.tsx

Co-authored-by: Bill <bluebill1049@hotmail.com>

* update video section and more resource

* update useWatch and useFieldArray doc

* finish translate all content

* clean up the object type

* Add all to useForm mode (#297)

* Update Important Code Sandbox + Add TS examples (#299)

* Update Code-examples for get-started API

* Update base js example

* Add a yarn install vs. npm

* Do Some Linting and add ts + CodeSandbox

* Add useEffect ui library effect

* Undo some changes to follow BlueBill's Pattern

* Add Large Controller Example V5 and V6 TS

* Remove yarn add

* Translate spanish (#300)

* [updated] main section in re-render translate to spanish

* [updated] translate to spanish re-render in homepage

* update setValue api

* fix button focus effect

* Feature/get started example update (#302)

* Update Code-examples for get-started API

* Update base js example

* Add a yarn install vs. npm

* Do Some Linting and add ts + CodeSandbox

* Add useEffect ui library effect

* Undo some changes to follow BlueBill's Pattern

* Remove yarn add

* Add Error CodeSanbox and TS example

* Add TS Schema Validation example and codesandbox

* Correctly Import SchmaValidationTs

* update migration guide

* Translate spanish (#301)

* [updated] main section in re-render translate to spanish

* [updated] translate to spanish re-render in homepage

* [updated] check Faq Page

Co-authored-by: Bill <bluebill1049@hotmail.com>

* fix all the code gap

* update codesandbox

* Fix type signature for handleSubmit in docs (#303)

https://react-hook-form.com/api#handleSubmit has:

`handleSubmit: (data: Object, e: Event) => () => void`

But the Typescript types in https://github.com/react-hook-form/react-hook-form/blob/master/src/types/form.ts are:

```
export type SubmitHandler<TFieldValues extends FieldValues> = (
  data: UnpackNestedValue<TFieldValues>,
  event?: React.BaseSyntheticEvent,
) => void | Promise<void>;

...

  handleSubmit: <TSubmitFieldValues extends FieldValues = TFieldValues>(
    callback: SubmitHandler<TSubmitFieldValues>,
  ) => (e?: React.BaseSyntheticEvent) => Promise<void>;

```

To simplify for the documentation, that line should be something like:

`handleSubmit: ((data: Object, e?: Event) => void) => (e?: Event) => void`

At its core handleSubmit executes a [partial application](https://en.wikipedia.org/wiki/Partial_application) in which we bind the form's validated data. At no time should handleSubmit *itself* be passed anything but a function, so let's make the documentation clear about this.

* Misc. Fix's and add SubmitHandler clarification (#304)

* Update Code-examples for get-started API

* Update base js example

* Add a yarn install vs. npm

* Do Some Linting and add ts + CodeSandbox

* Add useEffect ui library effect

* Undo some changes to follow BlueBill's Pattern

* Remove yarn add

* Allow for proper navigation to API page

* Add handSubmit Text to api page + codesandbox

* Update To Better (Bills) Controller TS

* add example to TS Page

* rename to clearErrors

* fix doc on setValue

* Support i18n in Subscribe Input Change section in Home (#305)

* support i18n in Subscribe Input Change section

* translate to jp

* Translated to jp in FAQs page (#306)

* fixed typo

* translate to jp

* fix

* fix link with api version toggle

* fix doc about clearErrors

* fix clear errors link

* Small Bug Fix and CodeSandbox v5/v6 seperation (#307)

* Allow TS to be copied from CodeArea

* Using "latest" defaults to 5.7.2, not 6.0.0-rc5

* Clearly Specify v5 vs. v6 CodeSandbox's

* Update custom validation resolvers

* separate unregister v5 and v6

* Fix Validation Resolver (PR requests)

* fix examples with email regex to support all TLD's (#308)

* [updated] review advanced page (#310)

* v6 and v5 seperation for ApiErrors + i18n work (#309)

* Using "latest" defaults to 5.7.2, not 6.0.0-rc5

* Clearly Specify v5 vs. v6 CodeSandbox's

* Add ErrorHandle Linkage Note (also i18n)

* Translate Migration Message (i18n work)

* Seperate V5 and V6 code & sandbox's

* Fix Code Example

* fix custom resolver codesanbox

* Update watch Code Examples and CodeSandbox's (#311)

* Feature/api doc work (#312)

* Separate generateCode functionality from CodeArea

* add key to video list

* remove generateCode from CodeArea

* Implement "Types"

* clean up the copy button

* only show JS icon if TS code is present

* include new video

* remove lodash from codeArea & enhance logic (#313)

* Adds eslint and fixes all resulting errors (#314)

* All Errors resulting from lint rules solved.

* tsx -> ts

* re-add gatsby-config require

* Update watch CodeExample + TS Code (#315)

* Implement "Types"

* Update Watch Code API

* Remove unused lodash

* update doc with v6 banner

* finalise the banner

* add is live

* update title

* fix padding and font size

* Added Reset Example and CodeSandbox (#316)

* Implement "Types"

* Remove unused lodash

* Add TS and CodeExample to reset docs

* Remove Styles

* Expand/improve setError Docs (#318)

* Implement "Types"

* Remove unused lodash

* Add TS and CodeExample to reset docs

* Remove Styles

* Push Better Typescript Patterns

* Correct Some Spelling Mistakes

* Add CodeSandbox and Simplified examples: setError

* update banner with CTA

* Added test tutorial (#317)

* added tutorial

* fixed bugs

* removed unused tags

* fixed sentence

* translated to jp

* fixed feedback

* removed video

* reduce couple lines with test example code

* add back id

* remmove spectrum icon

* refine testing description

* fix bugs (#319)

* translate contents

* revise korean translation - Home (#266)

* use `currentLanguage` data to 'TS Support' page

* revise korean translation - TS Support (#266)

* translate to jp (#321)

* revise korean translation - Advanced'(#266)

* revise korean translation - FAQs (#266)

* revise korean translations - Misc (#266)

* fixed sentence (#322)

* Enhance clearError docs + fix bug (#323)

* Implement "Types"

* Remove unused lodash

* Update clearError code fix CodeAreas Link

* Fix following Rebase

* Fix the rebase fix :/

* Improve English in formState (#326)

* Improve English in formState

* The correct name for formState.dirty is isDirty

Co-authored-by: Bill <bluebill1049@hotmail.com>

* fix the typo on multiple error

* include extra resource

* update dot points

* fix missing `isDirty` connection on API page

* revise korean translation - V6 API docs (#266)

* Enhance setValue Docs (#327)

* Implement "Types"

* Remove unused lodash

* Make Clear Errors More Readable

* Add TS and types example to setValue

* Show TS codeSandbox for Types rawCode

* V6 (#328)

* [updated] review advanced page

* [updated] first review api

* [updated] trastalte api

* update doc on should unregister

* Enhance getValue Docs (#329)

* Implement "Types"

* Remove unused lodash

* enhance getValues docs

* add more video resource

* update table title and design

* fixed code example

Co-authored-by: eatdesignlove <eatdesignlove@gmail.com>
Co-authored-by: vitorboccio <vitorboccio@gmail.com>
Co-authored-by: Kotaro Sugawara <kotarella1110@gmail.com>
Co-authored-by: keiya sasaki <34934510+keiya01@users.noreply.github.com>
Co-authored-by: Dan Dascalescu <ddascalescu+github@gmail.com>
Co-authored-by: Phillip ED Maier <pmaier983@gmail.com>
Co-authored-by: César Galindo <33326122+chestergalindo@users.noreply.github.com>
Co-authored-by: Brenton Partridge <bapartridge@gmail.com>
Co-authored-by: Glenn Morton <glenn@sandcastle.io>
Co-authored-by: Dohyung Ahn <me@rinae.dev>
Co-authored-by: keiya01 <keiya.s.0210@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants