How Do You Extract a CSS Selector from a Webpage Effectively? or What’s the Best Way to Find the Righ

22 Replies, 1800 Views

Ever tried the "Inspect" tool in Edge? It’s actually decent for css selector from webpage extraction.

Also, if the site uses BEM, you’re in luck—those class names are usually predictable.
Shortcut: Use `querySelector` in the console to test your css selector from webpage before committing. Like, `document.querySelector('.your-selector')`.

If it returns null, tweak it. Saves so much time!



Users browsing this thread: 1 Guest(s)