Comments (12)
Awesome, thanks man.
Installed 0.3.8 and it works fine!
from vscode-auto-close-tag.
Interesting bug, but I cannot repro it in my side. Could you please disable all other extensions and try again? I just want to make sure no other extension affect on this.
from vscode-auto-close-tag.
It happens to me too, even with all other extensions disabled (and workspace reloaded)
Weird thing is, it happens to existing files only, if I copy the content of a file where this happens to a new html file, it won't happen.
If I take an existing file where it happens. Even reducing the file to a simple:
<div>
</div>
will trigger the bug if you leave the cursor on the end of the <div>
from vscode-auto-close-tag.
me too.
and I set autosave onFocusChange.
from vscode-auto-close-tag.
Oh.. Still could not repro in my side even I set autosave onFocusChange. 🤔 Could you please let me know your Auto Close Tag version, VSCode version, OS info and other user settings you set in VSCode if possible. I want to see if there are some similar things in your side.
from vscode-auto-close-tag.
@formulahendry
last version vscode on OS X 10.11.6.
it happens with all other extensions disabled and reset custom settings.json
from vscode-auto-close-tag.
Hi all, to help troubleshoot this issue, could you please unzip the attached zip and install the vsix:
auto-close-tag-0.3.7.zip
Then try to repro the issue and show me the log by opening the developer console in the top menu bar: 'Help'-> 'Toggle Developer Tools':
from vscode-auto-close-tag.
Here is the console after changing the tab back to the html file with:
<div>|
</div>
cursor where the | pipe is
note that the text captured is the original file as committed (I show the bug after I deleted all lines and added only the <div></div>
there
from vscode-auto-close-tag.
@formulahendry
I think i know what's wrong with it and It's very weird.
maybe it's a bug vscode ide itself.(i don't know will it happend on windows?).
the text
prop in event.contentChanges[0]
is strange if project works with git. ( I debug your code on my machine ).
if a file is in version control, the event.contentChanges[0].text give me the whole file text....en..for example:
create test.html
<html>
<head>
</head>
<body>
</body>
</html>
then
git add test.html
Event.contentChanges [0] .text
returns me the entire file code, and the html is endsWith>
. IsRightAngleBracket
is equal to true
.
More seriously, contentChange.text
always returns the same html string (after tab change) before making changes using git add test.html
!!
This means that adding a blank line at the end of the file does not solve the problem unless you exec git add.
from vscode-auto-close-tag.
Thanks @shjyh and @lsharir for the very helpful information! 🙂 This should be the vscode bug. 🙄 Despite that, for quick turnaround, I have provided a hotfix in the extension side to eliminate this issue. You could install the latest version and have a try. 😎
from vscode-auto-close-tag.
I have created an issue for VS Code team. Keep this issue open for tracking.
from vscode-auto-close-tag.
Yeah, looks great.
Thanks a lot!
from vscode-auto-close-tag.
Related Issues (20)
- Tags forming with random words? HOT 1
- Extension causes high cpu load
- Extension issue
- Extension issue
- Extension causes high cpu load
- Extension causes in aprioate completions for typescript
- Extension issue
- All Extensions - "Reload Required"
- Doesn't close self-closing tags in HTML
- HTML tag position goes to the right a little (In a setting where enter "</" will also enter all)
- Creating issues in on non html or xml files HOT 1
- Extension issue
- Extension issue HOT 1
- Wrong closing tags in blade files
- Bug
- Fix: README.md
- auto closs
- Extension is deprecated. Included With Visual Studio Code HOT 1
- Auto close tag unresponsive, causing other extensions to stop
- Feature Request: Support for closing tags in Svelte (.svelte files)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vscode-auto-close-tag.