{"id":27251489,"url":"https://github.com/scarletsfiction/sfintercom","last_synced_at":"2025-04-11T01:10:07.669Z","repository":{"id":109493842,"uuid":"142738501","full_name":"ScarletsFiction/SFIntercom","owner":"ScarletsFiction","description":"Client-side cross-tab communication with same domain","archived":false,"fork":false,"pushed_at":"2020-01-29T18:36:47.000Z","size":9,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-11T01:10:02.014Z","etag":null,"topics":["broadcast","browser","cross-tab-communication","javascript","js"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ScarletsFiction.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2018-07-29T07:01:27.000Z","updated_at":"2023-03-30T18:14:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"ee6b807e-ba88-4f60-bb42-e9c40f9ecf24","html_url":"https://github.com/ScarletsFiction/SFIntercom","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScarletsFiction%2FSFIntercom","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScarletsFiction%2FSFIntercom/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScarletsFiction%2FSFIntercom/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScarletsFiction%2FSFIntercom/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ScarletsFiction","download_url":"https://codeload.github.com/ScarletsFiction/SFIntercom/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248322602,"owners_count":21084337,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["broadcast","browser","cross-tab-communication","javascript","js"],"created_at":"2025-04-11T01:10:05.059Z","updated_at":"2025-04-11T01:10:07.643Z","avatar_url":"https://github.com/ScarletsFiction.png","language":"JavaScript","funding_links":["https://patreon.com/stefansarya'"],"categories":[],"sub_categories":[],"readme":"\u003ca href='https://patreon.com/stefansarya'\u003e\u003cimg src='https://img.shields.io/endpoint.svg?url=https%3A%2F%2Fshieldsio-patreon.herokuapp.com%2Fstefansarya%2Fpledges\u0026style=for-the-badge' height='20'\u003e\u003c/a\u003e\n\n[![Written by](https://img.shields.io/badge/Written%20by-ScarletsFiction-%231e87ff.svg)](LICENSE)\n[![Software License](https://img.shields.io/badge/License-MIT-brightgreen.svg)](LICENSE)\n\n# SFIntercom\nSFIntercom is a client-side library that allow cross-tab communication with same domain.\nIt can broadcast to all listener on a different tab or window, but can't broadcast to other browser instance.\n\nThis library was useful for syncronizing message, notification, and other data.\n\n## Sample Usage\n\n```js\n// First tab\nvar client1 = new SFIntercom();\nclient1.on('log', console.log);\nclient1.on('warn', console.warn);\n\n// Second tab\nvar client2 = new SFIntercom();\nclient2.on('log', console.log);\nclient2.emit('log', 'Hello from second tab'); // Broadcast to all except this tab\n\n// Third tab\nvar broadcaster = new SFIntercom();\nbroadcaster.emit('log', \"Hello from third tab\"); // Broadcast to all\nbroadcaster.emit('warn', \"Hello warn\"); // Broadcast to all who listen to 'warn'\n```\n\n## Contribution\n\nIf you want to help in SFIntercom library, please fork this project and edit on your repository, then make a pull request to here.\n\nKeep the code simple and clear.\n\n## License\n\nSFIntercom is under the MIT license.\nBut don't forget to put the a link to this repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscarletsfiction%2Fsfintercom","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscarletsfiction%2Fsfintercom","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscarletsfiction%2Fsfintercom/lists"}