Quantcast
Channel: JavaScriptMVC Forum
Viewing all articles
Browse latest Browse all 3491

Re : Can you use a page's existing jQuery in steal?

$
0
0
I figured out steal.config.map I think!  What clued me in was the docs for steal.id and steal.idToUri.

  1. steal.config({
        map: {
            "*": {
                "jquery/jquery.js" : "jquery", // mapped items can go to other ids, right?
                "can/util/util.js": "can/util/jquery/jquery.js"
            }
        },
        paths: {
            "jquery": "/js/jquery.min.js" // here is the final destination for id "jquery"?  I just made it use mine, is this bad?
        },
        shim : {
            jquery: {
                exports: "jQuery"
            }
        },
        ext: {
            js: "js",
            css: "css",
            //less: "steal/less/less.js",
            //coffee: "steal/coffee/coffee.js",
            ejs: "can/view/ejs/ejs.js",
            //mustache: "can/view/mustache/mustache.js"
        }
    })



Viewing all articles
Browse latest Browse all 3491

Trending Articles