Skip to content

How to skip css! references in r.js builds? #204

Description

@tangst

I'm using grunt-contrib-requirejs, which packages r.js. The site I work on has wrapped the css.js file into a define module into the the global space. So, simply referencing

require(["css!some_file"],function(){}) 

works fine when you just use it inline without doing an r.js build and upload the file.

However, when trying to do a r.js build, I get the usual "Cannot read property 'normalize' of undefined" message. Is there a way to tell r.js that when it sees css! to ignore it for the build? I've tried

require.config({
   paths: {
     "css": "empty:"
   }
});

but that doesn't work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions