diff --git a/README.md b/README.md index 1afea9e..f964ada 100644 --- a/README.md +++ b/README.md @@ -176,6 +176,10 @@ var MyComponent = React.createClass({displayName: 'MyComponent', }); ``` +## Troubleshooting + +If you encounter a file compilation error, you can run `grunt --verbose` to see specifics about each file being transformed. + ## Contributing In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [Grunt](http://gruntjs.com/). diff --git a/tasks/react.js b/tasks/react.js index fa9b7ff..b167ee2 100644 --- a/tasks/react.js +++ b/tasks/react.js @@ -45,7 +45,7 @@ module.exports = function(grunt) { var compiled = []; grunt.util.async.concatSeries(files, function(file, next) { - grunt.log.writeln('[react] Compiling ' + file.cyan + ' --> ' + destFile.cyan); + grunt.verbose.writeln('[react] Compiling ' + file.cyan + ' --> ' + destFile.cyan); try { compiled.push(transform(grunt.file.read(file), options)); @@ -57,7 +57,7 @@ module.exports = function(grunt) { } }, function () { grunt.file.write(destFile, compiled.join(grunt.util.normalizelf(grunt.util.linefeed))); - grunt.log.writeln('[react] File ' + destFile.cyan + ' created.'); + grunt.verbose.writeln('[react] File ' + destFile.cyan + ' created.'); nextFileObj(); });