Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

component should be written as a pure function

//Probably you have Slint rules that does not allow you to do write convenient code
//Use a pure stateless component
export const myComponent = () => return ()

/*Disable Slint Rules */
// eslint-disable-next-line react/prefer-stateless-function
export class myComponent extends React.Component {
  ...
}
 
 
PREVIOUS NEXT
Tagged: #component #written #pure #function
ADD COMMENT
Topic
Name
2+3 =