diff --git a/lib/transforms/flattenRequireJs.js b/lib/transforms/flattenRequireJs.js
index <HASH>..<HASH> 100644
--- a/lib/transforms/flattenRequireJs.js
+++ b/lib/transforms/flattenRequireJs.js
@@ -77,7 +77,7 @@ module.exports = function (queryObj) {
                         if (requireJsRelationTypes.indexOf(outgoingRelation.type) !== -1) {
                             if (outgoingRelation.to.type === 'JavaScript') {
                                 assetGraph.removeRelation(outgoingRelation);
-                            } else if (outgoingRelation.to.type === 'Css' || outgoingRelation.to.type === 'Less') {
+                            } else if ((outgoingRelation.to.type === 'Css' || outgoingRelation.to.type === 'Less') && !/(?:^|\/)text!/.test(outgoingRelation.rawHref)) {
                                 var newHtmlStyle = new assetGraph.HtmlStyle({to: outgoingRelation.to});
                                 if (htmlStyleInsertionPoint) {
                                     newHtmlStyle.attach(htmlAsset, 'after', htmlStyleInsertionPoint);
flattenRequireJs: Keep css/less as AMD modules if it's included via the text plugin.