JSLint Weird assignment, required for closure compiler
问题 I'm using the closure compiler to minify and speed up my code but I'm running into some issues with JSLint when I try to export my functions. Basically, I have an object, foo{} with a function, foo.bar() that gets called via an external file as. In order for this function to be called externally I need to add some declarations to my script before it gets compiled: window['foo'] = foo; window['foo']['bar'] = foo.bar; This works great, but—as ever—JSLint thinks I'm mental for even attempting