Bridge the Gap: Mastering the Adapter Design Pattern in JavaScript