wycats/rake-pipeline-web-filters — Issue #1: Add "use strict" as an option for minispade filter
Author: jamesarosen
Created: 2011-11-29 00:11:22+00:00
State: open

It's a good general practice to add `"use strict";` to the top of each major function. It would be nice to have a `strict` option on the filter that would add it just inside the `function() { }` wrapper.

Why not just have the user put it in each source file? Because global `"use strict";` is a bad idea, so things like JSHint expect it to be inside a `function() {}()` call. To do this in the source files means that each source file would have to look like

```javascript
(function() {
"use strict";
...
}());
```

which would then get compiled to

```javascript
minispade.register('filename', function() {
(function() {
"use strict";
...
}());
});
```

There's nothing *wrong* with that, but it seems wasteful.