Why there is no suggestion in my vs code ? when i'm about typing "onClick, href, src, etc" it is not showing the suggestion but in my older code or download from github it's show up. i already try reinstall vscode, reset user setting and still the same.
here is some setting and i already install some extension but seems not work
I think you should have to add .jsx as a extension :"html"
Related
When I write some code, and then click Tab to autofill from context menu the cursor is now in the wrong position. It should be before ";" but for some reason it is after ";". Worked fine for about a year, and now suddenly something like this, any ideas?
This problem is related to snippets in vscode.
The easiest way to solve this is to use the snippet extension.
Install "HTML CSS Support" extension made by "ecmel" to visual studio code. Close the program and open it again and you are ready. Problem fixed.
Extension URL: https://marketplace.visualstudio.com/items?itemName=ecmel.vscode-html-css
Long way:
You can write your own or update snippets, to solve this.
Documentation to make your own snippets: https://code.visualstudio.com/docs/editor/userdefinedsnippets
I had same issue. I tried all of the solution proposals and searched snippets for it but can't found anything.
I was already using the html css support extension by ecmel. I deleted and reinstalled it, Closed the vscode program and open it again but I couldn't get any results. Finally downgraded vscode to 1.64 version from here and now cursor works like a charm. I wanted to write this answer for friends like me who did not get any results.
I'm new in VS Code and I'm trying to figure out what went wrong here because css won't work for me. The link is good because it opens with click + ctrl. Both files are in the same folder. So why isn't it working?
Edit saved:
Seems like you didn't save index.html. See the round dot? It means it's not saved.
Your code seems fine. Also, it's always better to use a browser than using built in preview.
Use an browser and save your files changes for see your proyect.
Save file and try opening it with a browser. I always prefer browser to test a file. Sometimes 2 browsers if it has a problem. I suggest you to use sublime text 3 or notepad ++ with vs code because it can save you from a lot of headaches. :)
I'm working on a web page project, with an HTML file and a CSS file only. I use Sublime Text 3 for a better programming environment, I also use XAMPP to debug my code and test it on Chrome.
When I'm saving my programming files, the HTML one is saving, but CSS one is not saving; I checked it in the directory and opened it to view if my editions are saved or no, they are, but they don't show up in the debug using XAMPP and Chrome.
Why aren't my changes showing up in debug?
Try deleting the Chrome Browser's Cache. It might be creating that problem
It doesn't let me comment, but this is adding onto the users answer of clearing the browser cache.
Clear browser cache in chrome: https://support.google.com/accounts/answer/32050?hl=en&co=GENIE.Platform%3DDesktop
If the issue resolves after clearing your browsing cache, what I usually do when working with stylesheets is use the Chrome browser in incognito mode, it usually doesn't store cache in that mode, so after closing the tab and revisiting, it should show all of the changes.
fisrt try to clear/delete your browsers cache and if that didnt work try the steps below.
Lets say all your css code is in a file called style.css, what you need to do is:
you can just change the name of your file to something else for example style2.css (dont forget to also change the name in html file)
or
create a new file for example new-style.css.
copy and paste all the css code that you have from style.css to
new-style.css.
and lastly just delete style.css.
after that you can rename new-style.css back to style.css Or you can
keep it like that. doesnt really matter as long as you remember to
change the link name in html as well.
It might not be the best way to solve this problem but it works.
I am trying to set up the mapping feature in Chrome canary. I followed the screenshots in this answer.
The main feature works, when I inspect an element, it points me to my local sass file and when I edit it, the local file safes, and the `sass --watch' is triggered. However, the browser does not refresh, even though on the "General" tab in devtools I have checked "Auto-reload CSS upon Sass save".
Should the browser reload? Is there a way to get it to reload?
Ps - I have compass but I can not use that as it does not support mapping, so I am compiling sass through the terminal
Thanks
You probably forgot this step:
In the Sources tab, find your generated CSS file, right click on it and choose Map to network resource, and select the same file name in the shown dropdown:
and then choose the matching file from your workspace:
It could be that the Sass-file is still compiling when Chrome tries to reload the CSS. Setting the 'Auto-reload CSS upon Sass save' Timeout to 5000 ms fixed it for me. When Chrome triggers the reload, it can even prevent Sass from recompiling the CSS.
I solved the problem by installing tincr extention and now when I save locally, the browser refreshes.
What I'm trying to do is to save the changes I make to CSS and HTML on different sites with Firebug.
Just to be clear, I don't expect Firebug to upload the changes to the server via FTP or anything. I just want to save the changes locally, so only I will be able to see them.
For example I've seen a few Firefox/Chrome extensions that add a download button under every video on Youtube, so I know it's possible to do that somehow.
If you have a different way to achieve what I'm trying to do, I'll be glad to hear about it.
(It doesn't have to be with Firebug.)
Thanks in advance!
If you don't mind using Web Developer Toolbar it's easy to save changes made to the DOM (and CSS).
When you install the toolbar, you'll get a "View Source" menu, click on that and choose "View generated source". Then just copy and paste that into a .html file.
You did not say if you alter your HTML or CSS, if CSS, FireFile is a very good addon for this.
Edit, with some Googling, i found FireDiff, which states that it can export changes made in Firebug, i have not tested it bit it's worth checking out.
You could try using Greasemonkey.
It has support for adding custom scripts that are run whenever you load a page (linked to which pages it should load on) and that can make changes to the page dynamically.
https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/
The http://chrispederick.com/work/web-developer/ web developer toolbar will let you add a user style sheet to a site which should achieve your goals.
This may or may not be exactly what you're asking for, but you can download the extension FireDiff in order to save changes made with FireBug. I made a little tutorial on how to do it here: https://www.youtube.com/watch?v=m4OmZLX2zd4
I have a somewhat simlar use-case that I solved differently. I'm not sure if it is what you are looking for or not. I'll describe the behavior and if that is helpful I'll explain exactly how I implemented it.
I changed the code that execute when you click "Run" (or Ctrl+Enter) to check to see if the first line of the code is a hard-coded string //LoadFromFile:<file path>. If it is, and the file exists then I pull the file off of the local file system and run it instead of executing the code in the console window. This way I can use an external text editor to write code.