1. First, understand the overflow-wrap attribute The CSS Since the Until one day The formal syntax of
2. What is the use of anywhere Before we explain the function of the technical attribute value Hard line breaks insert actual line breaks at the break points of the text, while soft line breaks actually remain on the same line, but appear to be divided into several lines. For example, The differences and similarities between anywhere and break-word In its normal state, To put it in layman's terms, if consecutive English characters can be separated without breaking, then do so. If this is not possible, then break them. Therefore, compared to break-all, there may be some blank space left. As shown in the following figure: For details, please refer to this article: "The difference between word-break:break-all and word-wrap:break-word". Let's talk about the different supports. The difference between For example, the following example: <p class="anywhere">I'm zhangxinxu.</p> <p class="break-word">I'm zhangxinxu.</p> p { display: inline-block; width: min-content; padding: 10px; border: solid deepskyblue; vertical-align: top; } .anywhere { overflow-wrap: anywhere; } .break-word { overflow-wrap: break-word; } The result in the Chrome browser is as follows: It can be seen that the minimum width of the element declared with As you can see, 3. Compatibility and Conclusion Therefore, it is not suitable for use in actual projects at present, so you just need to understand it. Moreover, this attribute is not used in regular text typesetting. Even if you know the value of this attribute, you will not think of using it. It is destined to be a forgotten CSS feature in the future. That’s all I have to say. I’ll give you a brief introduction to a new feature. Summarize This is the end of this article about the usage of the new CSS overflow-wrap property value anywhere. For more related CSS overflow-wrap new property value anywhere content, please search 123WORDPRESS.COM’s previous articles or continue to browse the related articles below. I hope that everyone will support 123WORDPRESS.COM in the future! |
<<: MySQL8.0.18 configuration of multiple masters and one slave
>>: Detailed explanation of custom events of Vue components
Table of contents Preface 1. Preparation 2. Insta...
Following the previous article 202 Free High-Qual...
1. Download address: mysql-8.0.17-winx64 Download...
This article shares the specific code of the WeCh...
Vue plugin reports an error: Vue.js is detected o...
Table of contents JavaScript function call classi...
This article describes how to install MySQL 5.7 f...
Table of contents Overview definition Instance Me...
1. Create a test table CREATE TABLE `mysql_genara...
This article uses examples to illustrate the diff...
Before reading this article, I hope you have a ba...
Preface When we installed the system, we did not ...
Let's imitate Taobao's function of displa...
Conversion between rgba and filter values under...
We don’t often encounter 404 pages when we browse...