Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
A utility library for cross-tab communication using localStorage.
crosstab is available through npm and bower and can be installed with the following command:
npm:
npm install crosstab
bower:
bower install crosstab
crosstab is a javascript utility library for inter-tab communication on the same domain. It offers the following features:
master
tab and updates the master tab if it closes or times out. This is useful for maintaining a single server connection across all tabs.Browser | Version Tested |
---|---|
IE | 9+ |
Chrome | 35+ |
FireFox | 30+ |
Safari | 6.1+ |
Most of the time, you will only need to do two things with crosstab, set up event handlers, and fire off events.
crosstab broadcasts messages like this:
crosstab.broadcast(event, data, destination);
If a destination is not specified, the message is broadcast to all tabs, including itself.
crosstab registers event handlers like this:
crosstab.on('eventName', function(message) {
// Handle event
});
The messages received by events have the following format:
var message = {
id: util.generateId(), // The unique ID of this message
event: event, // The name of the event
data: data, // The data to pass
destination: destination, // The destination tab
origin: crosstab.id, // The origin tab
timestamp: util.now() // The time the message was created
};
The event will not fire if the destination is present and differs from the id of the current tab.
I wanted to be able to have robust cross tab communication for the purpose of resource sharing (such as websockets). Though there are some libraries which have a similar goal, they all had subtle issues. This library aims to be the most correct it can be for supported browsers. This library was created with inspiration from the excellent intercom.js library, and addresses several of it's shortcomings:
crosstab solves these issues by dropping support for IE8 and using a lockless system that is entirely event driven (IE8 cannot pass messages via localStorage events, which is why intercom.js requires locking, because it supports IE8).
FAQs
A utility library for cross-tab communication using localStorage.
The npm package crosstab receives a total of 551 weekly downloads. As such, crosstab popularity was classified as not popular.
We found that crosstab demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.