Dart basic language beginner level chapter
This article is [ Learn from scratch and develop a Flutter App ]The first article on the road.
This article introduces the basic features of Dart, aiming to help you build a general understanding of Dart language and master its grammar.
We assume that the reader has a certain programming foundation. If you know the object-oriented languages su ...
Posted by ask9 on Mon, 06 Jan 2020 10:49:04 -0800
10 lines of code to realize the simple version of Promise
Before implementation, let's take a look at the call to Promise
const src = 'https://img-ph-mirror.nosdn.127.net/sLP6rNBbQhy0OXFNYD9XIA==/799107458981776900.jpg?imageView&thumbnail=223x125&quality=100'
const promise = new Promise(function (resovle, reject) {
var img = document.createElement('img')
img.onload ...
Posted by Locust on Mon, 06 Jan 2020 06:04:26 -0800
Play audio using Javascript?
I'm making games with HTML5 and Javascript.
How to play game audio through Javascript?
#1 building
If you don't want to clutter HTML elements:
var audio = new Audio('audio_file.mp3');
audio.play();
var audio = new Audio('https://interactive-examples.mdn.mozilla.net/media/examples/t-rex-roar.mp3'); audio.play();
T ...
Posted by coderWil on Mon, 06 Jan 2020 05:29:44 -0800
PHP export data to table instance
I found that there are many pages to export excel table for recent projects. I think this is also our common function. Now I can export it skillfully, but I remember that when I first exported it, there were some detours, so now I will record my export under the project of exhop framework (in fact, the export principles of Excel under different ...
Posted by MeanMrMustard on Mon, 06 Jan 2020 02:33:29 -0800
Analysis of Three Parameters of Navigation Hook
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------Global guard
router.beforeEach((to,from,next)=>{
//Jump from From to
// To: Routing object to the destination to be reached
...
Posted by Rowno on Sun, 05 Jan 2020 21:31:22 -0800
WebView dynamic injection JavaScript script
Demo address: https://gitee.com/chenyangqi/YouMeDai
Background introduction
stay Android interacts with JavaScript In this paper, we learned about the interaction between native and JS, but if we want to develop a good web page interaction with others, it is obvious that this web side does not define a jsBridge for us, which is a rogue who grab ...
Posted by fox_m on Sun, 05 Jan 2020 13:53:09 -0800
JS DOM Properties+JS Events
DOM Properties
console.log(ele.attributes) Gets the collection of attributes of an ele element
ele.attributes.getNamesItem(attr).nodeValue Gets the specified attribute value
ele.attributes[attr].nodeValue Gets the specified attribute value
ele.attributes.removeNamedItem(attr) Deletes the specified attribute
Create attributes and assign val ...
Posted by craka on Sun, 05 Jan 2020 11:50:33 -0800
Wechat applet search box
wxSearch elegant wechat applet search box1, FunctionSupport custom hot keySupport search historySupport search suggestionsSupport search history (record) caching2, Use1. Copy the whole wxSearch folder to the root directory
2. Introduction
// wxml Template in
<import src="/wxSearch/wxSearch.wxml"/>
<template is="wxSearch" data="{{wx ...
Posted by mlefebvre on Sun, 05 Jan 2020 09:01:06 -0800
JQuery implementation of the carousel graph and its principle
Source code:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>JQuery Rotation chart</title>
<style>
*{
padding:0;
margin:0;
...
Posted by Pig on Sun, 05 Jan 2020 00:36:42 -0800
JS Function Deep
Functions are objects in nature
Three Definitions
1. Literal = function declaration
function add() {
// body...
}
add();
2. var assignment expression
var add = function (argument) {
// body...
};
add();
var add = function fn(ar ...
Posted by [uk]stuff on Sat, 04 Jan 2020 23:51:28 -0800