Skip to content

Instantly share code, notes, and snippets.

View Rabbitzzc's full-sized avatar
🙃
seize the day!

Rabbitzzc Rabbitzzc

🙃
seize the day!
View GitHub Profile
@Rabbitzzc
Rabbitzzc / bubble-iframe.js
Created January 18, 2022 08:31 — forked from dmail/bubble-iframe.js
Bubbling iframe events
const bubbleIframeEvents = (iframe, document) => {
const iframeWindow = iframe.contentWindow
iframeWindow.addEventListener(
'mousemove',
(event) => {
const boundingClientRect = iframe.getBoundingClientRect()
const fakeEvent = new CustomEvent(
'mousemove',
{
@Rabbitzzc
Rabbitzzc / fork-and-push.md
Created January 9, 2022 15:11 — forked from zxhfighter/fork-and-push.md
如何给开源项目贡献代码

如何给开源项目贡献代码

分两种情况:

  • 代码仓库管理者给你添加该仓库的写入权限,这样的话可以直接push
  • 如果不能直接push(大多数情况),采用经典的fork & pull request来提交代码,下面讲述这种情况

fork & pull request

例如有个仓库https://github.com/ecomfe/esui.git,其采用了经典的分支开发模型,稳定后的代码提交到master分支,其余特性则在dev分支上进行开发,待成熟后合并回master分支。