Tag:selector

  • Fast review of CSS3 pseudo class selector

    Time:2019-12-10

    Preface If CSS is the basic skill of front-end development, then “selector” is the foundation of the foundation. If you are copying or learning these confusing selectors, then you will come to the right place, my old man This article will directly compare their features to help you quickly master them: first-child last-child first-of-type last-of-type […]

  • CSS style usage, selectors

    Time:2019-11-24

    There are three ways to use CSS in HTML: 1. In line style: set the same as the style attribute of the element <p style=”font-size:20px; color:red”>hello</p> Properties are separated by semicolons. 2. Internal style: define CSS style in the < style > element of < head > <style> p{font-size: 20px;color: red} </style> 3. External style: […]

  • 10 minutes to start Vue component Vue draggable

    Time:2019-11-7

    Vue combines the advantages of Angualr and react. Because of its easy to use and lightweight, it is widely used. It has become a hot front-end framework, attracting more and more front-end developers! In this article, we will take you to Vue draggable component quickly through a simple drag and drop example. First, you need […]

  • Use of plug-ins

    Time:2019-10-21

    In the process of learning and interviewing, we will focus on the original things, but in the actual development process, we seldom use the original to write projects. The first tier cities are Vue, react, and angular, and jQuery is also used, but it is less than the second tier cities, but not none. JQuery […]

  • Tag acquisition method with decimal point in CSS selector

    Time:2019-9-27

    Requirement specification Because there are decimal points, titles of 1, 1.1, 1.2, 1.11 in the section configuration of the project, at this time the ID and class of each line heading are set as unique tags. However, it is impossible to obtain documents directly with js, for example, $(‘ 3.22’) printing can only get documents. […]

  • Instance code for TeaPickerView data cascade selector function in Android

    Time:2019-8-31

    Github address YangsBryant/TeaPickerView (Github typesetting is better, I suggest you go here to see the details, if you feel good, click Star! ) Introducing module allprojects { repositories { google() jcenter() maven { url ‘https://www.jitpack.io’ } } } implementation ‘com.github.YangsBryant:TeaPickerView:1.0.2’ Main code public class MainActivity extends AppCompatActivity { @BindView(R.id.mButton) Button button; List<String> mProvinceDatas=new ArrayList<>(); Map<String, […]

  • JQuery selector

    Time:2019-8-19

    Link: jQuery selector Basic selector *Select all elements .classChoiceclassFor example:$(‘.mybox’) elementChoiceelementFor example:$(‘p’) #idChoiceidFor example:$(‘#box’) selector1,selectorNMultiple elements can be selected at the same time, such as:$(‘div, p.box, #phone’) Hierarchy Hierarchy parent > childSelect the specified child element under the specified element, such as:$(‘ul.tonav > li’) ancestor descendantSelect all descendant elements in an element, such as:$(‘form input’) […]

  • In-depth analysis of CSS selector grouping

    Time:2019-8-16

    Selector grouping Suppose you want both H2 elements and paragraphs to be grey. To achieve this, the easiest way is to use the following statement: h2, p {color:gray;} A rule is defined by placing the H2 and P selectors on the left side of the rule and separating them by commas. The style on the […]

  • JavaScript & jQuery method comparison

    Time:2019-8-6

    Reference link: https://juejin.im/post/5d2705d8e51d4577407b1dda Refer to the comment link http://youmightnotneedjquery.com/ JavaScript method getElementById() QuerySelector () matches the first element of the specified selector. QuerySelectorAll () returns all elements. createElement() createTextNode() insertBefore() firstChild() removeChild() getAttribute() setAttribute() .value addEventListener() removeEventListener() cloneNode() $(“…”).html(); document.querySelector(“…”).innerHTML=””; Specifies the element to insert content. $(“…”). append (); ending var list = document.querySelector(“…”); var […]

  • Instance code for setting label style by CSS selector

    Time:2019-4-17

    css selector Setting style on HTML tags can set properties for tags: <div style=”background-color: a2; height: 48px;”>Ah ah </div> We can also set selectors in the < head > tab so that each style only needs to be written once. <head> <meta charset=”UTF-8″> <title>Title</title> <style> <! – Write the selector here – >. </style> </head> […]

  • Selector Engine Sizzle in jQuery

    Time:2019-4-14

    Read the source code of Sizzle and analyze the version number of Sizzle.2.3.3。 Sizzle’s Github Home Page Browser native support element query method: Method name Method description Compatibility description getElementById Query elements based on element ID IE6+, Firefox 2+, Chrome 4+, Safari 3.1+ getElementsByTagName Query elements by element name IE6+, Firefox 2+, Chrome 4+, Safari […]

  • [jQuery] selector

    Time:2019-3-24

    jQuery JS class library is actually to simplify the development of Js, mainly the operation of DOM. JS class library predefines a series of objects and functions, reduces the difficulty of using JS, and is compatible with various browsers. Factory function The main purpose is to simplify locating page elements through functions.DOM objects are wrapped […]