Socket
Book a DemoInstallSign in
Socket

crossmania

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crossmania

the node module for doing cross-domain CRUD with the browser

latest
npmnpm
Version
0.2.8
Version published
Maintainers
1
Created
Source

crossmania

talk crossdomain with your browser. it's available through npm:

npm install crossmania

usage is simple:

var mania = require('crossmania'); // call .string() afterwards to talk raw strings

mania.get('/', function(request, respond) {
	respond({hello:'world'}); // yes we talk json
});
mania.post('/', function(request, data, respond) {
	respond(data); // we echo
});
mania.listen(80);

mania works by relying on cors based ajax if available (chrome, safari, firefox).
for IE8+ and Opera it uses an iframe proxy frame and the postMessage api. for IE7- and all others it falls back to an jsonp wrapper.

In the browser use the crossmania available for client-side javascript

Keywords

cross-domain

FAQs

Package last updated on 20 Mar 2012

Did you know?

Socket

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.

Install

Related posts