学习笔记学习笔记
主站博客
面试
前端
开发工具
Cesium
GitHub
主站博客
面试
前端
开发工具
Cesium
GitHub
  • 面试
  • 算法

    • hash哈希

      • lc-1-简-两数之和
    • top K

      • lc-215-数组中的第K个最大元素
      • lc-347-中-前 K 个高频元素
      • lc-LCR159-简-库存管理 III
    • 二叉树

      • lc-101-简-对称二叉树
      • lc-102-中-二叉树的层序遍历
      • lc-104-简-二叉树的最大深度
      • lc-105-中-从前序与中序遍历序列构造二叉树
      • lc-114-中-二叉树展开为链表
      • lc-226-简-翻转二叉树
      • lc-236-中-二叉树的最近公共祖先
    • 动态规划

      • lc-1277-中-统计全为 1 的正方形子矩阵
      • lc-221-中-最大正方形
      • lc-62-中-不同路径
      • lc-70-简-爬楼梯
      • lc-72-中-编辑距离
      • lc-746-简-使用最小花费爬楼梯
      • 背包-01背包
      • 背包-完全背包
    • 原地哈希

      • lc-33-中-搜索旋转排序数组
      • lc-442-中-数组中重复的数据
      • lc-448-简-找到所有数组中消失的数字
    • 图

      • lc-207-中-课程表
      • lc-997- 简-找到小镇的法官
    • 待分类

      • lc-11-中-盛最多水的容器
      • lc-121-简-买卖股票的最佳时机
      • lc-128-中-最长连续序列
      • lc-136-简-只出现一次的数字
      • lc-139-中-单词拆分
      • lc-152-中-乘积最大子数组
      • lc-20-简-有效的括号
      • lc-200-中-岛屿数量
      • lc-22-中-括号生成
      • lc-279-中-完全平方数
      • lc-31-中-下一个排列
      • lc-322-中-零钱兑换
      • lc-34-中-在排序数组中查找元素的第一个和最后一个位置
      • lc-39-中-组合总和
      • lc-416-中-分割等和子集
      • lc-42-难-接雨水
      • lc-437-中-路径总和 III
      • lc-438-中-找到字符串中所有字母异位词
      • lc-49-中-字母异位词分组
      • lc-53-中-最大子数组和
      • lc-55-中-跳跃游戏
      • lc-56-中-合并区间
      • lc-560-中-和为 K 的子数组
      • lc-647-中-回文子串
      • lc-79-中-单词搜索
    • 排序

      • 归并排序

        • 归并排序
      • 快排
      • 排序+双指针

        • lc- 524-中-通过删除字母匹配到字典里最长单词
        • lc-15-中-三数之和
        • lc-16-中-最接近的三数之和
        • lc-283-简-移动零
        • lc-3-中-无重复字符的最长子串
        • lc-75-中-颜色分类
      • 计数排序
    • 算法工具库js
    • 递归+回溯

      • lc-17-中-电话号码的字母组合
      • lc-77-中-组合
      • LCR-083-中-全排列-不重复
      • LCR-084-中-全排列-重复
    • 链表

      • lc-142-中-环形链表 II
      • lc-148-中-排序链表
      • lc-160-简-相交链表
      • lc-19-中-删除链表的倒数第 N 个结点
      • lc-287-中-寻找重复数
  • 手撕代码

    • 柯里化 Curring
    • h5 Evnet详解
    • promiseify化
    • script标签详解
    • vue-SSR服务端渲染
    • vue双向绑定
    • vue核心原理全解
    • 路由的实现
    • 原型链
    • 变量提升
    • 宏任务、微任务
    • 左右两栏布局
    • 异步
    • 微前端
    • 实现js的filter函数
    • 实现promise
    • 捕获、冒泡
    • js中new的本质
    • Object.xxx
    • this
    • 反射Reflect,、代理Proxy
    • 基础类型
    • 深拷贝-浅拷贝
    • 继承
    • 跨域
    • 闭包
    • 防抖-节流

h5 Evnet详解

Window Event Attributes

AttributeValueDescription
onhashchangescriptScript to be run when there has been changes to the anchor part of the a URL
onloadscriptFires after the page is finished loading
onpopstatescriptScript to be run when the window's history changes
onafterprintscriptScript to be run after the document is printed
onbeforeprintscriptScript to be run before the document is printed
onbeforeunloadscriptScript to be run when the document is about to be unloaded
onerrorscriptScript to be run when an error occurs
onmessagescriptScript to be run when the message is triggered
onofflinescriptScript to be run when the browser starts to work offline
ononlinescriptScript to be run when the browser starts to work online
onpagehidescriptScript to be run when a user navigates away from a page
onpageshowscriptScript to be run when a user navigates to a page
onresizescriptFires when the browser window is resized
onstoragescriptScript to be run when a Web Storage area is updated
onunloadscriptFires once a page has unloaded (or the browser window has been closed)

Keyboard Events

AttributeValueDescription
onkeydownscriptFires when a user is pressing a key
onkeypressscriptFires when a user presses a key
onkeyupscriptFires when a user releases a key

Mouse Events

AttributeValueDescription
onclickscriptFires on a mouse click on the element
ondblclickscriptFires on a mouse double-click on the element
onmousedownscriptFires when a mouse button is pressed down on an element
onmousemovescriptFires when the mouse pointer is moving while it is over an element
onmouseoutscriptFires when the mouse pointer moves out of an element
onmouseoverscriptFires when the mouse pointer moves over an element
onmouseupscriptFires when a mouse button is released over an element
onmousewheelscriptDeprecated. Use the onwheel attribute instead
onwheelscriptFires when the mouse wheel rolls up or down over an element

Drag Events

AttributeValueDescription
ondragscriptScript to be run when an element is dragged
ondragendscriptScript to be run at the end of a drag operation
ondragenterscriptScript to be run when an element has been dragged to a valid drop target
ondragleavescriptScript to be run when an element leaves a valid drop target
ondragoverscriptScript to be run when an element is being dragged over a valid drop target
ondragstartscriptScript to be run at the start of a drag operation
ondropscriptScript to be run when dragged element is being dropped
onscrollscriptScript to be run when an element's scrollbar is being scrolled

Clipboard Events

AttributeValueDescription
oncopyscriptFires when the user copies the content of an element
oncutscriptFires when the user cuts the content of an element
onpastescriptFires when the user pastes some content in an element

Media Events

AttributeValueDescription
onabortscriptScript to be run on abort
oncanplayscriptScript to be run when a file is ready to start playing (when it has buffered enough to begin)
oncanplaythroughscriptScript to be run when a file can be played all the way to the end without pausing for buffering
oncuechangescriptScript to be run when the cue changes in a element
ondurationchangescriptScript to be run when the length of the media changes
onemptiedscriptScript to be run when something bad happens and the file is suddenly unavailable (like unexpectedly disconnects)
onendedscriptScript to be run when the media has reach the end (a useful event for messages like "thanks for listening")
onerrorscriptScript to be run when an error occurs when the file is being loaded
onloadeddatascriptScript to be run when media data is loaded
onloadedmetadatascriptScript to be run when meta data (like dimensions and duration) are loaded
onloadstartscriptScript to be run just as the file begins to load before anything is actually loaded
onpausescriptScript to be run when the media is paused either by the user or programmatically
onplayscriptScript to be run when the media is ready to start playing
onplayingscriptScript to be run when the media actually has started playing
onprogressscriptScript to be run when the browser is in the process of getting the media data
onratechangescriptScript to be run each time the playback rate changes (like when a user switches to a slow motion or fast forward mode)
onseekedscriptScript to be run when the seeking attribute is set to false indicating that seeking has ended
onseekingscriptScript to be run when the seeking attribute is set to true indicating that seeking is active
onstalledscriptScript to be run when the browser is unable to fetch the media data for whatever reason
onsuspendscriptScript to be run when fetching the media data is stopped before it is completely loaded for whatever reason
ontimeupdatescriptScript to be run when the playing position has changed (like when the user fast forwards to a different point in the media)
onvolumechangescriptScript to be run each time the volume is changed which (includes setting the volume to "mute")
onwaitingscriptScript to be run when the media has paused but is expected to resume (like when the media pauses to buffer more data)
在 GitHub 上编辑此页
上次更新:
贡献者: 国wei
Prev
柯里化 Curring
Next
promiseify化