The Web browser is different from the previous webview, our web browser does not require the user to enter the preceding HTTP, and can realize the automatic layout, this word is a summary of the previous words. To create a new project, and then drag a text label, let's look at some of the tools in the lower right corner, the first one being the alignment constraint:
The second one is the pin constraint, which aligns up and down:
The third one is to clear the constraints and clear the Set constraints:
We set a PIN constraint below and click Add:
To run a look, we find that the text box is already constrained:
View Textlabel's Dimension editor to see that its height is 30 fixed:
Let's drag a webview down below, the height from the top cannot be less than 30, add the constraint:
The main content of this statement is to be bound.
Swift UI special training 21 Web browser