None
NL
How to handle array values in react-hook-form
[]
Blog by Martijn Hols
const articles = [ { id : 1 , title : 'Intro' , publishedAt : '2024-04-01' , tags : [ 'meta' ] , } , { id : 2 , title : 'License' , publishedAt : '2024-04-01' , tags : [ 'meta' ] , } , { id : 3 , title : 'The security implications of packages in front-end apps' , publishedAt : '2024-04-15' , tags : [ 'security' , 'packages' , 'npm' , 'frontend' ] , } , ] id } > < td > < input type = " checkbox " name = { name } checked = { checked } onChange = { toggle } onBlur = { onBlur } disabled = { disabled } /> </ td > < td > { article . The ` value ` prop is an array of the currently selected article ids and the ` onChange ` prop is an event handler that will be called with the new value whenever the user selects or deselects an article.