JS vs HTML/CSS in VS Code

Hey all. I have a feeling that writing JS requires much more manual input than HTML and CSS do. When writing HTML and CSS, I feel like flying and like I can write many lines of codes quickly because of suggestions that pop up and me pressing enter without having to type them out. When writing JS, I feel like I have to write a lot of characters for a usable suggestion to pop up, if it pops up at all. If not, I have to write the entire thing out. Am I doing something wrong? Am I the only one? Is it possible to address this?
6 Replies
Jochem
Jochem2y ago
I wouldn't worry about it too much tbh. Typing shouldn't be the majority of time spent when programming, even without intellisense
Azyrum
Azyrum2y ago
You spend most of your time googling and copy pasting
Jochem
Jochem2y ago
I'd have said thinking, but also that
Azyrum
Azyrum2y ago
Damn i didn't think of that
Jochem
Jochem2y ago
You do get quicker at using something like intellisense though, and if you find yourself repeating certain structures a lot in ways that aren't easily abstracted to functions, it can be worth setting up snippets of your own say you have some boilerplate for doing a fetch call to your own API, which always needs a bearer token added, a .catch with some default error handling, and a .then(r => r.json()), you could add a snippet to VSCode (or honestly any other IDE / code editor) where you type fapi and hit tab to complete a bunch of code there's also some built in ones, and there's snippet packs for various libraries and frameworks on the extension store
Zenon
ZenonOP2y ago
Okay, I tried creating a custom snippet for myself and this is perfect. Cool, thanks.
Want results from more Discord servers?
Add your server