plugins.js optimization