scroll view constraint in xcode 11

I got the answer after one hour spend. You can use scrollview like old scrollview when you give a constraints to your scrollview that time select scrollview from the options.

enter image description here


You can deselect this option and use scroll view like old version

enter image description here


Basically here frameLayoutGuide is an alias for ScrollView frame and contentLayoutGuide is an alias for content size. You can skip their use and position your scroll view content just like you use to before. If you want to use Layout guides, pin your contentView to contentLayoutGuide (leading, trailing, top, bottom constraints) and set your positioning constraints (centre horizontally or vertically) to frameLayoutGuide. Below is the image that shows content view positioned using layout guides.

content view positioned inside scroll view

If you want to follow old way of positioning refer this.