is attribute in Vue and data of subcomponent
1, is attribute
According to the HTML specification, elements such as < Table >, < UL >, < ol >, < Select > can only contain specific elements. When the template tag uses restrictive elements, there will be a bug in rendering. As shown in the following example:
<div id="root">
<tab ...
Added by CaptainChainsaw on Thu, 02 Jan 2020 14:40:50 +0200
Android: weight, margin, padding
Title Map
weight detailed explanation
weight is an attribute used to divide regions equally.
Case code
dashucoding
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/LinearLayout"
android:layout_width="match_parent"
android:layout_h ...
Added by GroundZeroStudio on Thu, 02 Jan 2020 06:33:02 +0200
Three level linkage effect of provincial and urban areas, using city picker
City picker can help us to complete the three-level linkage effect of provincial and urban areas conveniently and quickly. It is simple and fast. We can download the plug-in on the official website: http://tshi0912.github.io/city-picker/
Download this: city-picker-master.zip
After decompression:
Copy the contents of dist to ...
Added by L0j1k on Thu, 02 Jan 2020 00:33:11 +0200
JavaScript dynamic web page - snowflakes falling
Design ideas: 1. Define a certain number of snowflake layers, each layer contains a snowflake;
2. The horizontal swing of snowflake is the method of Math.sin(), sine function;
3. The vertical direction of snowflake is to increase a certain distance each time by self adding method;
4. Snowflakes vary in size;
The methods ado ...
Added by onno182 on Wed, 01 Jan 2020 19:57:13 +0200
Js objects and functions
Two ways of Js custom object
An object initializer constructs an object
var marry={
name:"marry",
age:2,
shout:function(){
alert("I am:"+this.name+",This year:"+this.age);
},
action:function(){
alert("Will eat");
}
};
alert(marry.name);
alert(marry.age);
marry.shout();
marry.action();
Two constructo ...
Added by ecljc on Wed, 01 Jan 2020 14:56:55 +0200
jquery application - find element correlation (selector);
Child element selector:
// Big premise: all the selected ones are used to decorate Div. is div the first child of its parent element (without limitation)? Is it the last child? Is it the index child? Is it the only child?
$('div:first-child') // Match all div s that are the first element
$('div:last-child') // Mat ...
Added by johnnyboy16 on Mon, 30 Dec 2019 19:38:35 +0200
Query result field type in yii2 database
The default return from the yii2 database query is an AR object, where the field type is essentially the same as the database, but if asArray is used to return in an array, the default field type is all string, and if this json_encode is returned to the App end, it will be killed by the engineers of the strongly typed languages Android/IOS, and ...
Added by Eratimus on Mon, 30 Dec 2019 09:49:12 +0200
Detailed description of Beautiful Soup Library
install
pip install lxml
pip install beautifulsoup4
Verify installation
In [1]: from bs4 import BeautifulSoup
In [2]: soup = BeautifulSoup('<p>Hello</p>', 'lxml')
In [3]: print(soup.p.string)
Hello
About Beautiful Soup
Parsers supported by Beautiful Soup
Parser
By comparison, lxml parser is a better choice
Jus ...
Added by artied on Sun, 29 Dec 2019 17:52:44 +0200
C# LINQ Learning Notes 5: LINQ to XML
Extract this note from: https://www.cnblogs.com/yaozhenfa/p/CSharp_Linq_For_Xml.html And record the learning process for future reference.
1. Generating xml
1.1 Create simple xml
/// <summary>
/// CreateXml class
/// </summary>
public class CreateXml
{
/// <summary>
/// Return xml File Path ...
Added by andrewgk on Sat, 28 Dec 2019 12:06:02 +0200
Java Date Time API Series 9----Difference between Period and Duration of the new Date Time API class in the java.time package in Jdk8
1.Period
final modifier, thread safe, date-based amount of time in ISO-8601 calendar system, such as 2 years, 3 months, 4 days.
Main attributes: number of years, months, days.
/**
* The number of years.
*/
private final int years;
/**
* The number of months.
*/
private final int months;
/**
* The nu ...
Added by lordshoa on Fri, 27 Dec 2019 22:10:46 +0200