JavaScript Scattered notes

JavaScript basicsJS composition: DOM BOM ECMAScriptECMAScript: "Translation function" JS in the most central part of the profession is called the interpreter almost no compatibleDom:document Object Model ability to manipulate HTML---"Document has

[JS Master's Road] my open source JavaScript framework Gdom-Selector usage

The Gdom framework is a DOM and string processing framework I developed, and the current version is 1.0.0. Use the same method as jquery, and use jquery to Gdom, currently 1.0. The 0 version of the selector fully supports the CSS3 selector . Do not

JavaScript's map loop, foreach Loop, filter loop

1. Map loopLet Arr=[1,2,3,4]; (function (Value,key,arr) {//value, index, array (default = selected array) return item; Returns an array of all undefined if no return, number is index +1 (key+1)})//returns an array2. Foreach LoopLet Arr=[1,2

JavaScript syntax and types

VarDeclares a variable, optionally initializing it to a valueLetDeclares a local variable of a block scope, optionally initializing it to a valueConstDeclares a read-only constantVariableA JS identifier must start with a letter, underscore, or

Easy to understand JavaScript closures

Helow, Hello, let's talk about JavaScript closures today.What is a closure packageThe official explanation is too abstract to say here, let's take a look at the code first.function A () { function B () { console.log ("hellow closure");

Type of JavaScript automatic conversion advanced gameplay Jsfuck

0 PrefaceThe first is accidentally in the public number (programmer Big Coffee) saw a JS high-force lattice code, and then through the links inside jump to the Jsfuck wiki, like the maze to find the treasure feeling, exclamation JS automatic type

JavaScript's looping structure and classic topics

First, JS in the loop structureSteps to perform the loop structure1, declare the cyclic variable;2, judge the cycle conditions;3, the implementation of the circulation body operation;4, update the loop variable;5, then loop execution 2-4, until the

The BOM object for JavaScript (two location objects)

One, the Location object provides information related to the currently loaded document and has some navigational features. The Location object is a property of the Window object and is also a property of the Document object. Window.location and

JavaScript Asynchronous Download Promise implementation

General download is directly open a link on the line.var URL = ' XXXX '; (URL)In fact, this will have some problems:1. The browser prohibits opening a new window, resulting in the inability to downloadSo how to solve it?Such1 href=

JavaScript indexOf () method and LastIndexOf () method

One, definition and usageThe IndexOf () method returns the position of the first occurrence of a specified string value in a string.The LastIndexOf () method returns the location of the last occurrence of a specified string value, which is searched

JavaScript prototype chain Learning

functionfoo () {}foo.prototype.z= 3;varobj =Newfoo (); Obj.y= 2; obj.x= 1; obj.x;//1OBJ.Y;//2Obj.z;//3typeofobj.tostring;//' function '' Z 'inchObj//trueObj.hasownproperty (' z ');//falseFirst, we define a function object by using function foo ().

Four different property detection methods in JavaScript comparison

Tag: span indicates false differentiate BLE method inherit ASC logFour different property detection methods in JavaScript are compared to 1. Using the In methodvar o = {x:1}; inch // true inch // false inch // true, the inherited property can be

Common methods for Global, Math, and date objects in JavaScript

The common methods of global, Math, and date types in JavaScript are as follows:1 /*2 The global object in JS is a nonexistent object, and the method inside it can call3 Common methods:4 1 encodeURI Convert the URI byte, do not change the special

JavaScript prototypes and built-in objects 1

Prototype definition Each object has a prototype The prototype is still an object Simulating the implementation of object-oriented inheritance Prototype chain The prototype of the object is also a prototype Objects

The function type of javascript

One, function definitionA function is actually an object that has properties and methods as well as other reference types. Functions can be defined in three ways, namely, function declaration syntax definitions, function expression definitions, and

Basic use of JavaScript summary ①

JavaScript usesJavaScript is a lightweight programming language, and JavaScript is a programming code that can be inserted into an HTML page, and JavaScript is inserted into the HTML page and can be performed by all modern browsers.The script in the

Common methods of event binding in JavaScript

To get JavaScript to respond to a user's actions, we first bind the event handler to the DOM element. The so-called event handler function is the function that handles the user operation, and different operations correspond to different names.In

JavaScript (in volume) notes you don't know

you don't know JavaScript (medium volume)   JavaScript (in volume) notes you don't know

Deep copy and shallow copy of JavaScript

There are two types of data in JS:1. Base type: number, String, Boolean, Null, Undefined2. Complex Type: Object, Arraydeep and shallow copies are only for complex types of data , because the definition of the underlying type data will re-open up new

"Dry" JavaScript DOM programming Art Learning Note 7-9

Vii. Dynamic creation of tagsIn the document does not write placeholder pictures and text code, in the case can invoke JS dynamic creation, document support is better.Add function Prepareplaceholder on the basis of the original addloadevent

Total Pages: 5379 1 .... 395 396 397 398 399 .... 5379 Go to: GO

Alibaba Cloud 10 Year Anniversary

With You, We are Shaping a Digital World, 2009-2019

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

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: and provide relevant evidence. A staff member will contact you within 5 working days.