You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be beneficial to add the 'use strict' directive to all cjs files in this repo. Strict mode can improve performance by eliminating some JavaScript features that hinder optimizations. It also helps avoid subtle bugs by enforcing more consistent scoping and variable declarations.
At present this directive is dotted around a handful of files in the repo.
It would be beneficial to add the
'use strict'
directive to all cjs files in this repo. Strict mode can improve performance by eliminating some JavaScript features that hinder optimizations. It also helps avoid subtle bugs by enforcing more consistent scoping and variable declarations.At present this directive is dotted around a handful of files in the repo.
The MDN article on strict mode alludes to it, but the V8 JS engine used by Node will use more optimised execution paths when strict mode is enabled. See related Stack Overflow discussion for an example.
Happy to make a PR to resolve this.
The text was updated successfully, but these errors were encountered: