What is props in ReactJS, Is it the same $scope of angular? -


what props in reactjs? same $scope of angularjs? can't seem understand props in react, since im new it. thank in advance.

they not equivalent:

angular $scope object defines context of variables/properties/functions of controller object.

react props actual arbitrary values consumed component function/class.


react docs:

"conceptually, components javascript functions. accept arbitrary inputs (called "props") , return react elements describing should appear on screen."

angular docs:

"scope object refers application model. execution context expressions."


Comments

Popular posts from this blog

php - Permission denied. Laravel linux server -

google bigquery - Delta between query execution time and Java query call to finish -

python - Pandas two dataframes multiplication? -