Enable strict mode and applyed Module pattern

The code now is ECMAScript Strict Mode compliant.