git reset --soft HEAD~1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { Client, LocalAuth } = require('whatsapp-web.js'); | |
const qrcode = require('qrcode-terminal'); | |
// Initialize the WhatsApp client | |
const client = new Client({ | |
authStrategy: new LocalAuth() | |
}); | |
// Generate and display the QR code in the terminal | |
client.on('qr', (qr) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
document.addEventListener('DOMContentLoaded', () => { | |
const textBox = document.getElementById('your_id'); | |
textBox.addEventListener('keydown', (event) => { | |
if (event.key === 'Enter') { | |
const keyword = textBox.value; | |
const googleSearchUrl = `https://www.google.com/search?q=${encodeURIComponent(keyword)}`; | |
window.location.href = googleSearchUrl; | |
} | |
}); |