node package manager



Greenkeeper badge

Build Status

jQuery-inspired AJAX request library.


ES6 use

With StealJS, you can import this module directly in a template that is autorendered:

import plugin from 'can-ajax';

CommonJS use

Use require to load can-ajax and everything else needed to create a template that uses can-ajax:

var plugin = require("can-ajax");

AMD use

Configure the can and jquery paths and the can-ajax package:

<script src="require.js"></script>
        paths: {
            "jquery": "node_modules/jquery/dist/jquery",
            "can": "node_modules/canjs/dist/amd/can"
        packages: [{
             name: 'can-ajax',
             location: 'node_modules/can-ajax/dist/amd',
             main: 'lib/can-ajax'
    require(["main-amd"], function(){});

Standalone use

Load the global version of the plugin:

<script src='./node_modules/can-ajax/dist/global/can-ajax.js'></script>