Coda 2: How to enable Auto Closing Tag support - autocomplete

I am using CODA 2 for mac and I want the editor to complete my closing Tag!
example:
I am typing:
<div>
I want the editor to autocomplete the
</div>
tag
I have already checked the plugin store of coda: https://panic.com/coda/plugins.php
but without success.
Any idea?

Simply use a editor as visual studio code or sublime text. Every editor doesn't contain the support for auto closing tags

just type </
Its not a plugin as such but this is how you complete tags in Coda2.

Related

VScode "linkedEditing" not working for php files

I want to be able to easily edit HTML tags together. There is a built-in option for this in Visual Studio Code.
It works fine for HTML files. Buy why not for php files?
Does anybody know a work-around?
For example, let's say I wanted to change this div into a section. It should automatically select both opening tag and the closing tag.
Assuming you have html inside a PHP file. The simplest solution would be:
double click the element to edit
Holding control key double click the closing element ( open and close elements should be highlighted now)
type to edit the element
For now VS Code doesn't handle PHP with editor.linkedEditing.
But you can install Auto Tag Rename extension which will work for PHP files as well.
The extension will ignore certain file types if editor.linkedEditing = true, so you can install it without any conflicts.

Can't get rid of double cursors on tags in Visual Studio Code

I have this problem just recently whenever I click on one tag, say a <div>, it automatically puts cursors on both the starting <div> and the ending </div> all together.
I have tried re-install vscode itself, deleted settings, un-installed extensions, none of it worked.
Still couldn't find a solution ...
How can I fix this? Thanks in advance.
When I paste classes, because of the double cursors at the divs, it will end up like this:
Search for html.mirrorCursorOnMatchingTag in Settings and uncheck it

Visual Studio Code disable auto closing tags

I'm trying to prevent auto closing tags, but the following setting doesn't seem to work:
{
"html.autoClosingTags": false,
}
What else must be done to make auto-closing tags go away?
Just in case anyone looking at this is finding that HTML tags are still being automatically closed inside JSX files. The setting you need is:
{
"javascript.autoClosingTags": false,
"typescript.autoClosingTags": false
}
Open Visual Studio Code, go to Preferences -> Settings
Under the User Settings tab, click Text Editor, and search for the setting Auto Closing Tags. Uncheck HTML: Auto Closing Tags
This search results also allow you to disable auto closing for JavaScript and TypeScript, if desired.
Based on Visual Studio Code 1.64.2 for macOS.
For me, the solution was in an extension. I had the Auto Close Tag extension installed (who knows when I though that was a good idea) that was overriding the built in autoclose. Disabling the extension fixed it.
Take a look through your enabled extensions and see if there's any that might be adding this behavior.
The following worked for me:
Go to File > Preference > Setting (Ctrl + ,)
Extension > HTML
And remove tick from the "Auto Closing Tags".
Hope this helps. Cheers :)
Disabling autoclosing for only TypeScript generics
To eliminate autoclosing on TS <generic> tags, but leave it on otherwise, install the Auto Close Tag VSCode extension and add the following lines to your JSON user settings:
{
"auto-close-tag.disableOnLanguage": [
"typescript",
"typescriptreact"
]
}
Further Reading: TypeScript Generics: Adds closing "Tag" to type specifier #17
You might need to delete the comma after "false" - Visual Studio Code doesn't seem to like commas after the last statement in preferences.
Just ran into this problem and I went to preferences -> settings -> extensions -> HTML -> disable autoclosing of HTML tags. Hope this helps!
I just looked this one up myself and noticed there was no verified answer. Those saying you have to go to the HTML portion are absolutely correct, if you don't uncheck that checkbox under HTML: Auto Closing Tags then you will keep getting the closing tags.

Autocomplete of custom JavaScript functions in Sublime Text

I am using Sublime Text to code my website where I have a JavaScript file with a lot of functions. I use those functions quite frequently and every time I do, I have to type the whole function out.
I noticed that for each function, I could create a Sublime Text snippet with a shortcut. However there is a huge list of functions and they keep changing.
Is there a way where in I could just import this JavaScript file and this snippet file is created, such that I have my autocompletes ready to use?
A simple snippet that creates three opening and closing p tags:
<snippet>
<content>
<![CDATA[
<p>
$1
</p>
<p>
$2
</p>
<p>
$3
</p>
]]>
</content>
<tabTrigger>p3</tabTrigger>
<scope>text.html</scope>
</snippet>
Save it as html-p3.sublime-snippet in (Mac OS X) /Users/yourname/Library/Application Support/Sublime Text 2/Packages/User and you can enter p3+tab to create three <p> tags. The $1, $2, $3 are where your cursor will jump after you press tab. This allows you to easily add content without having to select manually.
This great blog post explains everything you need to know about Sublime Text snippets:
You can use snippets for CSS as well as HTML (actually, you can use snippets with any language or text that works inside Sublime Text).
To summarize, you can put all of your function snippets in between the <snippet><content><![CDATA[ *content here*]]></content></snippet> and save it as a .snippet file in the default preferences folder of Sublime Text.
Sublime Text should automatically autocomplete the function names (not the parameters) if everything is in one big file. The only possible issue I can think of is that Sublime Text doesn’t recognize the file type. Check if View → Syntax is set to JavaScript.
If you want full autocompletion with parameters, try Tern for Sublime.
You can try javascript plugin for sublime which will help in auto completion while writing code in js.
Here is the list of javascript plugin:
http://www.sitepoint.com/essential-sublime-text-javascript-plugins/
Here is the way to setup plugin in sublime:
How to install plugins to Sublime Text 2 editor?

How to change jEdit autoclose html tag functionality?

jEdit autocloses the last open html tag when typing
I want jEdit to close the open tag automatically (as it closes a bracket) and places the cursor between the tags.
How can I do this?
jEdit does not auto-close any brackets.
I guess you are using the FirstMate plugin or something similar which is providing that functionality.
The functionality you are searching is in the XML plugin which also handles HTML.
In its settings you have an option for autoclosing on typing "