Create A Simple JavaScript App to Generate QR Codes
Traversy Media
View ChannelAbout
Traversy Media features the best online web development and programming tutorials for all of the latest web technologies from the building blocks of HTML, CSS & JavaScript to frontend frameworks like React and Vue to backend technologies like Node.js, Python and PHP
Latest Posts
Video Description
Let's create a simple QR Code generator app with JavaScript, QRcode.js and Tailwind CSS. 💻 Github Repo https://github.com/bradtraversy/qr-code-generator 🧑💻 Live Demo https://qrcodes.tech 💻 QRCode.js Library: https://github.com/davidshimjs/qrcodejs ⭐ Special $9.99 Promo For My Tailwind CSS Course: https://www.udemy.com/course/tailwind-from-scratch/?couponCode=5DAY999 ⭐All Courses https://traversymedia.com 💖 Show Support Patreon: https://www.patreon.com/traversymedia PayPal: https://paypal.me/traversymedia 👇 Follow Traversy Media On Social Media: Twitter: https://twitter.com/traversymedia Instagram: https://www.instagram.com/traversymedia Linkedin: https://www.linkedin.com/in/bradtraversy Timestamps: 0:00 - Intro 1:09 - Side Project Motivation 2:31 - QRCode.js Library Intro 3:16 - Dependency Setup 6:39 - Tailwind CSS Layout 20:42 - Start JavaScript & Get Form Inputs 23:03 - Show & Hide Spinner Functions 25:05 - Generate QR Code 27:28 - Clear UI Function 28:40 - Create Save Button 32:48 - Get QR Code Image Source 34:50 - Clear Button From UI
Upgrade Your iPhone Experience
AI-recommended products based on this video
![iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White](https://m.media-amazon.com/images/I/61i3XjcGu1L._AC_SL1500_.jpg)
iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White

Kaistyle for Magsafe Car Mount【20 Strong Magnets】 Magnetic Phone Holder for Car Phone Holder Mount Dash Cell Phone Holders for Your Car Accessories for Women Men for iPhone 17 Pro Max 16 15 14 13 12 ClimatePartner certified
![Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard](https://m.media-amazon.com/images/I/712lUnThXpL._AC_UL960_FMwebp_QL65_.jpg)
Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard

LISEN Retractable Car Charger, 69W USB C Car Accessories Adapter for iPhone 17 USB C Charger Fast Charging, Gifts for Women Men, Travel Essentials, for iPhone 17 Pro Max Air 16 15 14 13 12 Samsung S25

Apple AirPods 4 Wireless Earbuds, Bluetooth Headphones, Personalized Spatial Audio, Sweat and Water Resistant, USB-C Charging Case, H2 Chip, Up to 30 Hours of Battery Life, Effortless Setup for iPhone

Belkin BoostCharge Lightning Cable - 6.6ft/2M - MFi Certified Apple iPhone Charger USB to Lightning Cable - iPhone Cable - iPhone Charger Cord - Apple Charger - USB Phone Charger - Black

Wireless Bluetooth Mouse for Apple iPad iPhone MacBook Android Samsung Tablet Phone Dual-Mode Rechargeable 2.4G Portable Computer Mice for Windows Laptop Notebook PC Mac Desktop USB Receiver (Black)

Apple EarPods Headphones with Lightning Connector, Wired Ear Buds for iPhone with Built-in Remote to Control Music, Phone Calls, and Volume

Apple AirPods Pro 2 Wireless Earbuds, Active Noise Cancellation, Hearing Aid Feature, Bluetooth Headphones, Transparency, Personalized Spatial Audio, High-Fidelity Sound, H2 Chip, USB-C Charging

Anker iPhone 16 Charger, 2-Pack 20W Fast USB C Charger Block, for iPhone 16/16 Pro Max/15 Series/iPad Pro and More (White, 2 Pack & 2 Cable)

Anker USB C to USB C Cable, Type-C 60W Fast Charging Cable (6FT, 2Pack) for iPhone 16 Series, iPad mini 6 and More (Black) ClimatePartner certified
![Apple Watch Series 10 [GPS 46mm case] Smartwatch with Rose Gold Aluminium Case with Light Blush Sport Band - M/L. Fitness Tracker, ECG App, Always-On Retina Display, Water Resistant](https://m.media-amazon.com/images/I/61nNNMI1cFL._AC_UL960_FMwebp_QL65_.jpg)
Apple Watch Series 10 [GPS 46mm case] Smartwatch with Rose Gold Aluminium Case with Light Blush Sport Band - M/L. Fitness Tracker, ECG App, Always-On Retina Display, Water Resistant
![Apple Watch Series 10 [GPS 42mm case] Smartwatch with Jet Black Aluminium Case with Black Sport Band - S/M. Fitness Tracker, ECG App, Always-On Retina Display, Water Resistant](https://m.media-amazon.com/images/I/6105jZyXyPL._AC_UL960_FMwebp_QL65_.jpg)
Apple Watch Series 10 [GPS 42mm case] Smartwatch with Jet Black Aluminium Case with Black Sport Band - S/M. Fitness Tracker, ECG App, Always-On Retina Display, Water Resistant
![iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White](https://m.media-amazon.com/images/I/61i3XjcGu1L._AC_SL1500_.jpg)
iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White

Kaistyle for Magsafe Car Mount【20 Strong Magnets】 Magnetic Phone Holder for Car Phone Holder Mount Dash Cell Phone Holders for Your Car Accessories for Women Men for iPhone 17 Pro Max 16 15 14 13 12 ClimatePartner certified
![Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard](https://m.media-amazon.com/images/I/712lUnThXpL._AC_UL960_FMwebp_QL65_.jpg)
Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard

LISEN Retractable Car Charger, 69W USB C Car Accessories Adapter for iPhone 17 USB C Charger Fast Charging, Gifts for Women Men, Travel Essentials, for iPhone 17 Pro Max Air 16 15 14 13 12 Samsung S25
![PEHAEL 3+3Pack for iPhone 17 Pro Max Privacy Screen Protector with Camera Lens Protector Full Coverage Anti-Spy Tempered Glass Film 9H Hardness Easy Installation Bubble Free [6.9 inch]](https://m.media-amazon.com/images/I/61PnVkv6KKL._AC_UL960_FMwebp_QL65_.jpg)
PEHAEL 3+3Pack for iPhone 17 Pro Max Privacy Screen Protector with Camera Lens Protector Full Coverage Anti-Spy Tempered Glass Film 9H Hardness Easy Installation Bubble Free [6.9 inch]
![Ailun 3 Pack Screen Protector for iPhone 16 Pro Max [6.9 inch] + 3 Pack Camera Lens Protector with Installation Frame,Sensor Protection,Dynamic Island Compatible,Case Friendly Tempered Glass Film](https://m.media-amazon.com/images/I/815keamN-BL._AC_UL960_FMwebp_QL65_.jpg)
Ailun 3 Pack Screen Protector for iPhone 16 Pro Max [6.9 inch] + 3 Pack Camera Lens Protector with Installation Frame,Sensor Protection,Dynamic Island Compatible,Case Friendly Tempered Glass Film
![iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White](https://m.media-amazon.com/images/I/61i3XjcGu1L._AC_SL1500_.jpg)
iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White

Kaistyle for Magsafe Car Mount【20 Strong Magnets】 Magnetic Phone Holder for Car Phone Holder Mount Dash Cell Phone Holders for Your Car Accessories for Women Men for iPhone 17 Pro Max 16 15 14 13 12 ClimatePartner certified
![Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard](https://m.media-amazon.com/images/I/712lUnThXpL._AC_UL960_FMwebp_QL65_.jpg)
Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard

LISEN Retractable Car Charger, 69W USB C Car Accessories Adapter for iPhone 17 USB C Charger Fast Charging, Gifts for Women Men, Travel Essentials, for iPhone 17 Pro Max Air 16 15 14 13 12 Samsung S25

ANKER 737 Power Bank, 24,000mAh 3-Port Laptop Portable Charger with 140W Fast Charging, Smart Display, for Outdoor Work, Compatible with iPhone 16/15/14 Series, Vision Pro, Samsung, MacBook, and More
![iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White](https://m.media-amazon.com/images/I/61i3XjcGu1L._AC_SL1500_.jpg)
iPhone Charger Cord [MFi Certified] 3Pack 0.9M Lighting Cable Power Delivery Charging Cord Compatible with iPhone 14 13 13 Pro Max 12 12 Pro Max 11 XS XR X 8 iPad,White

Kaistyle for Magsafe Car Mount【20 Strong Magnets】 Magnetic Phone Holder for Car Phone Holder Mount Dash Cell Phone Holders for Your Car Accessories for Women Men for iPhone 17 Pro Max 16 15 14 13 12 ClimatePartner certified
![Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard](https://m.media-amazon.com/images/I/712lUnThXpL._AC_UL960_FMwebp_QL65_.jpg)
Car Phone Holder for Magsafe [78+LBS Strongest Suction & 2400gf Magnetic] 360° Adjustable Car Phone Mount, Phone Holders for Your Car for iPhone 17 Pro Max 16 15 14 13 12 Air Plus (Carbon Fiber) Global Recycled Standard



























![Learn The MERN Stack [5] - Implementing Redux](https://imgz.pc97.com/?width=500&fit=cover&image=https://i.ytimg.com/vi/iI5h4-pChho/hqdefault.jpg)
![Learn the MERN Stack [2] - Express API & MongoDB](https://imgz.pc97.com/?width=500&fit=cover&image=https://i.ytimg.com/vi/5yTazHkDR4o/hqdefault.jpg)



![Node.js & Pusher Real Time Polling App [1] - Initial Back End](https://imgz.pc97.com/?width=500&fit=cover&image=https://i.ytimg.com/vi/SSDED3XKz-0/hqdefault.jpg)




