Can requirejs build a single optimization output with plugins in cdn?

36 Views Asked by At

main.js:

requirejs.config({
    css: "https://cdnjs.cloudflare.com/ajax/libs/require-css/0.1.10/css",
    fontawesome: "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome"
});
requirejs(["css!fontawesome"]);

app.build.js:

({
    name: "main",
    out: "built.js",
    paths: {
        css: "empty:",
        fontawesome: "empty:"
    }
})

r.js -o app.build.js throws:

Error: TypeError: Cannot read property 'normalize' of undefined
In module tree:
    main

Seems that options like 'exclude' only works with modules?

0

There are 0 best solutions below