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
The BlockListItem component is currently using a class component and the ReadableContentView component to handle the max width of the canvas and provide alignment styles. We want to refactor this component to use a custom hook (depending on #5614) and a functional component instead.
The proposed changes are:
Replace the usage of ReadableContentView with a custom hook that will handle the max width of the canvas and provide alignment styles. The hook will return just the styles and should leverage the useWindowDimensions hook.
Calculate the getMarginHorizontal in the same custom hook that will be created from ReadableContentView to improve performance, then we would just have one View that will have all of this data.
Refactor the BlockListItem component to be a functional component instead of a class component.
The text was updated successfully, but these errors were encountered:
The
BlockListItem
component is currently using a class component and theReadableContentView
component to handle the max width of the canvas and provide alignment styles. We want to refactor this component to use a custom hook (depending on #5614) and a functional component instead.The proposed changes are:
ReadableContentView
with a custom hook that will handle the max width of the canvas and provide alignment styles. The hook will return just the styles and should leverage the useWindowDimensions hook.getMarginHorizontal
in the same custom hook that will be created fromReadableContentView
to improve performance, then we would just have oneView
that will have all of this data.BlockListItem
component to be a functional component instead of a class component.The text was updated successfully, but these errors were encountered: