You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you are adding a component or making any change in the editor, the editor runs in development mode. Hence, if your component code is not right, the moment you drag & drop a buggy component, the editor will crash.
One of the reasons could be that you haven't provided the required values for props as the initial value in the component manifest.
For button, the intiial values look like this
Some of the props (styles or custom or any other props) may be required i.e. not optional for the component you are writing. You should check if you have handled the undefined value for a prop properly or not. If a prop is optional, you should make sure that you have handled the edge cases when that prop's value is undefined.
When you drag & drop a Button, it appears with some good style. An avid reader can notice all the CSS that was written as the initial value for the Button. Similarly, the Button component has an intial value of custom.text set as Submit.
You can discuss the initial value in the issue corresponding to that discussion if not already mentioned in the issue.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
When you are adding a component or making any change in the editor, the editor runs in development mode. Hence, if your component code is not right, the moment you drag & drop a buggy component, the editor will crash.
One of the reasons could be that you haven't provided the required values for props as the initial value in the component manifest.
For button, the intiial values look like this
Some of the props (styles or custom or any other props) may be required i.e. not optional for the component you are writing. You should check if you have handled the
undefined
value for a prop properly or not. If a prop is optional, you should make sure that you have handled the edge cases when that prop's value is undefined.When you drag & drop a
Button
, it appears with some good style. An avid reader can notice all the CSS that was written as the initial value for the Button. Similarly, theButton
component has an intial value ofcustom.text
set asSubmit
.You can discuss the initial value in the issue corresponding to that discussion if not already mentioned in the issue.
Beta Was this translation helpful? Give feedback.
All reactions