Zeng.js Save

make a communication between different tabs or windows.

Project README

About zeng.js

The name comes from the DreamWorks Animation's movie. Mr Zeng is a supporting protagonists in the Kung Fu Panda, is a palace servant too. what does he do ?

as zeng's quote:

I'm just the messenger.

zeng.js simply make a communication between different tabs or windows. is a mini javascript library without any else frameworks. only 70+ lines.

Install

npm install zeng.js

How To Use

emit event in the one page

import zeng from 'zeng.js'

zeng.emit('EVENT_NAME', arg1, arg2, ...)

receive event in other pages

zeng.on('EVENT_NAME', (arg1, arg2, ...) => {
  // do something
})

online demo: https://mblur.com/demos/zeng/

Browser Support

modern browsers.

Open Source Agenda is not affiliated with "Zeng.js" Project. README Source: alienproX/zeng.js
Stars
29
Open Issues
0
Last Commit
6 years ago
Repository

Open Source Agenda Badge

Open Source Agenda Rating