According to our country official document writing stipulation, the date of the time inscription should be abbreviated the Chinese character numeral, but is not the Chinese character and the Arabic numeral mix, is not the Chinese character and the English mixed use. But in actual writing it is always easy to write a date like "200" (number 0) or "Two oo years" (Capital Letter O), which is clearly incorrect and not good-looking. How to correctly enter the standard
Recently I found myself writing JavaScript code is bloated, so I began to study the shorthand method of JavaScript. This will make our JavaScript code look refreshing and also improve our technology. So what's the shorthand for an empty judgment?The following is a shorthand method for determining null.The code is as follows
Copy Code code as follows:
The shorthand for JavaScript developers
This article is based on years of JavaScript coding experience and is suitable for all developers who are using JavaScript programming.
The purpose of this article is to help you more skillfully use the JavaScript language for development.
The article will be divided into two parts: the preliminary article and the advanced article.
Preliminary Article 1. Three-object Operators
The following is a good example.
Part 1 Font ShorthandThe naming rules for CSS are named in English alphanumeric and underscore (usually lowercase). The advantages of shorthand CSS font are three: one is easy to write (like a keyboard shortcut), the other is to simplify the code, and the third is to help you familiarize yourself with and understand CSS.First, the font properties mainly include the followingFont-family,font-style,font-variant,font-weight,font-size,fontfont-family(font
recently started to study the shorthand method for JavaScript, and here's a short method for judging null Recently I found myself writing JavaScript code is bloated, so I began to study the shorthand method of JavaScript. This will make our JavaScript code look refreshing and also improve our technology. So what's the shorthand for a null judgment??nbsp; The fo
CSS abbreviationMultiple rows of CSS attributes are declared as one row, also knownCSSCode optimization. The biggest benefit of CSS shorthand is that it can significantly reduce the size of CSS files. In fact, there are many other benefits. A bloated and messy CSS style sheet makes debugging difficult. Especially when a team is designing, your bloated CSS code will reduce the efficiency of other members of your team.
Today, storm has compiled some CSS
Shorthand Argument NamesSwift automatically provides shorthand argument names to inline closures, which can is used to refer to the values of the Closure ' s arguments by the names,, $0 $1 $2 , and so on.If You use these shorthand argument names within your closure expression, you can omit the closure ' s argument list from it s definition, and the number and typ
CSS Shorthand refers to the shorthand of multiple lines of CSS properties, also known as CSS code optimization or CSS abbreviations . The biggest benefit of CSS shorthand is the ability to significantly reduce the size of CSS files, optimize the overall performance of the site, easier to read.The following are common CSS shor
In Jni, when we use Getfieldid/getstaticfieldid or Getmethodid/getstaticmethodid and define Jninativemethod, we need to represent the type of the member variable, Or a function to pass in a parameter or return type. JNI represents the type of field, or the type of a function passed in a parameter or return value, in the form of char*. for member variables, the type of the member variable can be represented directly by a shorthand of the Java type For
Original: http://www.jb51.net/article/47234.htmThe recent discovery of the JavaScript code that I wrote was rather bloated, so I began to study the shorthand method of JavaScript. This way, we can make our JavaScript code look fresh and improve our technology. So how do you abbreviate the judgment?The following is a shorthand method for judging null.The code is as follows: ifnullundefined‘‘) { var variab
CSS shorthand refers to the shorthand of multiple lines of CSS properties, also known as CSS Code optimization or CSS abbreviations. CssThe biggest benefit of shorthand is the ability to significantly reduce the size of CSS files, optimize the overall performance of the site, more easily readRead.The following are common CSS
Mac defaults to UNIX systems, and the UNIX system itself does not have these shorthand commands, so you can use them by setting aliases for the commandsView all command aliases that have been set on this computer: aliasSet command alias: Alias Ll= ' Ls-alf 'The execution command is valid only in the current shell, and can be set in the user's. Bash_profile for long-term use, so that each login can be used with these
In daily work, javascript some common shorthand skills, will directly affect our development efficiency, now the common skills are organized as follows:1. Null (null, undefined) validation When we create a new variable, we usually verify that the value of the variable is empty (null) or undefined (undefined). This is an often-considered validation for JavaScript programming.Non-optimized code:if NULL ") {Let variable2 = variable1;}Optimized code:In th
If you want to set all values to be displayed, you should limit the use of shorthand property declarations as much as possible.Common abuses:Padding, margin, font, background, border, Border-radius "?? Isn't that what I used to do?In most cases, we do not need to specify all values for the shorthand property declaration. For example, the heading element of HTML only needs to set the value of the top, bottom
Order:
Font-size Line-height font-family
{ font-size: 12px} { font:}
Where Line-height is a Text property , but it can also be used as a complement to the Font-size value , separated by a slash (/) . 200%/1.2
When you use the shorthand property font , all ignored values are reset to the default values.
{ font:}{ font:}{ font-size: 150%}
Results
Why H2 no italic effect?
Because the value ignored by
CSS shorthand refers to the shorthand of multiple lines of CSS properties, also known as CSS Code optimization or CSS abbreviations.The biggest benefit of CSS shorthand is the ability to significantly reduce the size of CSS files, optimize the overall performance of the site, easier to read.The following are common CSS shorth
= ' red ';
Car.wheels = 4;
Car.hubcaps = ' spinning ';
Car.age = 4;
The following writing can achieve the same effect:
var car = {
colour: ' Red ',
wheels:4,
hubcaps: ' Spinning ',
age:4
}
This is much simpler, and you don't have to use the name of the object over and over again.So the car is defined, maybe you will encounter invaliduserinsession problems, which only you will encounter when using IE, as long as you remember, do not write a semicolon in front of the rig
HTML is shorthand for Hypertext Markup Language, which is the most basic web language.
HTML is a language defined by tags, and the code is made up of tags.
HTML code is not case sensitive.
The HTML code starts with
The first part is to add some auxiliary or attribute information to the HTML page, the content of which will be loaded first.
The body part is where the page data is actually stored.
HTML is
Box model shorthand:
If the values for top, right, bottom, and left are the same, such as the following code: margin:10px 10px 10px 10px; Abbreviated as: margin:10px;
If top and bottom values are the same, left and right values are the same. margin:10px 20px 10px 20px; abbreviated as: margin:10px 20px;
If the value of left and right is the same. margin:10px 20px 30px 20px; abbreviation: margin:10px 20px 30px;
Colo
Some CSS shorthand tipsThe abbreviated font for 1.font has optional options and required options such as Font-style, Font-weight, Font-variant, can be written without writing, but must be placed before Font-size and font-family if written. And the required font-family must be put on the last side.p{font-style:italic; font-weight:bold; font-variant:small-caps; font-size:12px; font-family:arial; } can be abbreviated into p{font:italic bold small-caps
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.