emmetio / brackets-emmet Goto Github PK
View Code? Open in Web Editor NEWEmmet plugin for Brackets editor
Home Page: http://emmet.io
License: MIT License
Emmet plugin for Brackets editor
Home Page: http://emmet.io
License: MIT License
Hi @sergeche - we now have a centralized extension registry for Brackets extensions, so users can browse and install extensions directly from within the app. Since Emmet is one of the most popular extensions, it would be great if you could upload it to the registry through the web app: https://brackets-registry.aboutweb.com/. You can just sign in with GitHub, then drag the ZIP file for your extension onto the drop area. Whenever you need to update the extension, you can just upload a new ZIP file and users will be able to update with one click.
Live preview for abbreviation*
In Aptana Studio there is a thing, that during writing the the abbreviation, in bottom is showing the result, what it will be, here is the screenshot
Is it possible do such thing for Adobe Brackets's Emmet plugin?
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/1290166-live-preview-for-abbreviayion?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).Every time I have Emmet enabled I am unable to use just left curly brace in CSS(ALTGR + B)
sprint 41 + Emmet 1.1.3 + win7 machine
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
With javascript file open it overrides the toggle comment shortcut of editor and don´t work correctly
Your readme installation can be updated for Brackets Sprint 22. Now it's possible to use File > Install Extension > https://github.com/emmetio/brackets-emmet and it actually works without restarting Brackets, cloning or opening Finder.
I noticed that the Emmet extension uses several low-level (non "public") Brackets APIs for file IO. Sine they can change without warning, it would be better to use the higher level "official" APIs:
brackets.fs.readFile()
-> FileSystem.getFileForPath().read()
DocumentManager.getDocumentText(path)
(which will include any unsaved changes)brackets.fs.writeFile()
-> FileSystem.getFileForPath().write()
brackets.fs.readdir()
-> FileSystem.getDirectoryForPath().getContents()
(Note: we just introduced a new, cleaner file API in Brackets Sprint 34. The suggestions above are based on that API. If you were to release an update using the Sprint 34+ APIs, users with Sprint 33 would still be able to download the older version of your extension that doesn't require Sprint 34).
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/1290125-avoid-using-low-level-brackets-fs-apis?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).As I found on http://emmet.io/blog/beta-v1-1/ there is support for jade
, but only since v.1.1 (beta). This brackets
extension has emmet
only v.1.0.1 (so no jade
support, as it appears in the editor: when working on any .jade
file).
Is it possible to compile the original emmet from https://github.com/emmetio/emmet and so add the support for jade
and eventually slim
languages to this brackets
extension? Would be great to use emmet in brackets.
P.S. could one reuse any actual plugin from any other editor's extension?
Hi,
I've had trouble with the last two builds (25 and 26) with code completion in scss files, nothing happens. For instance, if I expand abbreviation on "mr" I get "< mr > < /mr >" instead of "margin-right:". Not sure if this is something local on my machine, I just tried deleting everything Brackets related and reinstalling, but with same issue. I've also tried with no other extensions other than Emmet, with same result. Anyone with advice or similar issue would be appreciated. Thanks, and let me know if I can help!
Ryan
Hello
After I updated to version 39 Brackets, keymap.json in my settings do not work anymore.
"match_pair_outward": "Ctrl-B"
I configured keymap.json but Brackets default settings appear to me. See the picture please:
This shortcut is very important, so if you can help.
OS is Windows 8.1
In the cheatsheet [http://docs.emmet.io/cheat-sheet/]:
form#search.wide
should be expanded to:
<form id="search" class="wide"></form>
, instead when I run the example in brackets
it is expanded to:
<form action="" id="search" class="wide"></form>
Does the action=""
appeared as a new staff (I don't know if it is only a brackets
specific or if it is generally emmet
) and the cheat-sheet should be updated?
if (foo) {
Result: Cursor is indented to the same column as the beginning of if
.
Expected: Cursor is indented inward past the if
, as it is when Emmet is not installed.
Looks like you should be checking the language/more for the current file and verifying that it's HTML-ish.
Brackets sprint 38 experimental build 0.38.0-12606 (release 4df8afdad)
Emmet extension installed from Brackets Extension Manager.
Failed to load resource file://localhost/Users/thyme/Library/Application%20Support/Brackets/extensions/lib/codemirror.js
[Extension] failed to load /Users/thyme/Library/Application Support/Brackets/extensions/user/brackets-emmet Error: Script error for: ../../lib/codemirror
http://requirejs.org/docs/errors.html#scripterror /utils/ExtensionLoader.js:209
errback /utils/ExtensionLoader.js:209
I noticed two.
There probably are more issues as the file type is not being recognized properly. Would be great Emmet could recognize scss as it does recognize less.
With the latest Brackets build (Sprint 25), whenever I have Emmet installed it breaks code completion in Brackets.
For example, when I'm in a CSS file in a CSS rule declaration:
h1 {
[cursor here]
}
I type "font-f" and the code hint shows "font-family".
However, when I hit enter it just adds a line break and leaves the previous line with "font-f" rather than completing "font-family".
When I remove Emmet, Brackets works fine again.
I realize this may be a conflict between Emmet, Brackets, and some other extension, although I've tried removing all my other extensions and the problem still persists as long as Emmet is installed.
Let me know if I can give you any more information -- I love Emmet (it's what makes Brackets most powerful in my opinion) but I also am too used to code completion to go back now =)
expand_abbreviation_with_tab not auto expanding like in previous versions of Brackets.
On a fresh install of Brackets sprint 39, Emmet is not working. I updated Emmet, still not working. I removed all other extensions except Emmet and it still does not work. I completely uninstalled Brackets and reinstalled with only Emmet, still nothing. I've manually installed, I've installed from the URL, and I've used the extension manager; nothing.
Using Windows 7 64 bit. Please let me know if there is anything else I can try or provide. Thank you!
When using this action, cursor focus is wrong; so I must hit Tab twice or use mouse click to be able to type the abbreviation I want to wrap with.
Would be great to have focus in the box right after typing Shift+Ctrl+A.
When working in LESS, the vendor prefixes are not added automatically like they are in a CSS file.
trf =>
-webkit-transform: ;
-ms-transform: ;
-o-transform: ;
transform: ;
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
There is no such functions in plugin for Brackets, is scheduled for Brackets?
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/1290149-update-image-size-and-encode-decode-image-to-data-url-for-brackets?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).While working with HTML in a .html.erb file, the tab key don't Expand the Emmet abbreviations. With standart HTML - all good.
I try to add this line in editor.js:
"erb": "html"
But that does not work
Make the extension look "pretty" in the Extension Manager.
Here's an example from one of my extensions you can use as a template:
https://github.com/lkcampbell/brackets-indent-guides/blob/master/package.json
Can you add support for the CSS vendor prefixes functionality?
If you load Brackets tip-of-tree with Emmett you'll get the following console warnings:
Cannot assign Ctrl-Enter to io.emmet.expand_abbreviation. It is already assigned to edit.openLineBelow
Cannot assign Ctrl-K to io.emmet.remove_tag. It is already assigned to navigate.toggleQuickDocs
Cannot assign Ctrl-Up to io.emmet.increment_number_by_1. It is already assigned to view.scrollLineUp
Cannot assign Ctrl-Down to io.emmet.decrement_number_by_1. It is already assigned to view.scrollLineDown
Cannot assign Ctrl-J to navigate.jumptoDefinition. It is already assigned to io.emmet.split_join_tag
These shortcuts are all used by Brackets core features now. You could take over them by programmatically un-registering the Brackets shortcuts first, but it'd be better to choose different shortcuts for Emmett that don't conflict with the Brackets defaults.
Note: depending on the timing of extension loading, some of the warnings can be reversed unpredictably -- instead of the Emmett shortcut not working, the Brackets core shortcut may be blocked and the Emmett shortcut takes its place (as in the last warning above).
Hi,
First of all, thank you so much for your plugin, I don't know if I would install any text edittor if it doesn't support emmet today.
So when you want to wrap a text with an abbreviation "ctrl shift a" the second half of the dialog is cut so you cannot click the button, plus it doesn't have focus so you have to click in the input field and hit "Enter".
I'm using brackets sprint 34
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/3981900-the-alert-dialog-for-wrap-with-abbreviation-is-cut-and-doesn-t-have-focus?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).While Emmet is installed and enabled on Brackets, when we select some text and press enter, the text is not erased but moved one line down (the default behavior is to erase the text and keep the cursor on the new line for more text to be entered).
Check this Youtube video to see this behavior in action.
http://youtu.be/C5ye9c5pScw
⌘⇧↑ and ⌘⇧↓ are used by default to select all the text from the cursor to the start / end of the document.
I used brackets key remapper to reassign them (https://bitbucket.org/sacah/brackets-key-remapper)
Perhaps we could change them (and the 0.1 / 10 increment decrement keys) to ⌘⇧] and ⌘⇧\
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
Brackets Sprint 34
I've created a snippets.json file, and set the extensions path
{
"javascript": {
"snippets": {
"fn": "function ${1:name} (${2:arguments}) {\n\t$3\n}\n"
}
}
}
In the editor when i type: fn[tab]
it works but it stops at name
, if I press [tab]
again, it enters a \t
, it doesn't jump to arguments
.
Also there is a behavior that I would like to remove, when I enter: asdasds[tab]
it converts to <asdasds>|</asdasds>
, is this a normal? Should I hack the extension or there is something simpler to disable?
If I set following to true, it suppresses the [tab] expand / insert behavior of emmet:
AppInit.appReady(function () {
// insert code hints on tab instead of enter
CodeHintManager.setInsertHintOnTab(true);
})
Thanks
!
is expanded to
<!DOCTYPE html>
html(lang="en")
head
meta(charset="UTF-8")
title Document
body
but should be
<!DOCTYPE html>
html(lang="en")
head
meta(charset="UTF-8")
title Document
body
this works for html emmet, where there is no need for indentation:
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<title>Document</title>
</head>
<body>
</body>
</html>
but it is crucial for jade
because the emmet's expansion is compiled to jade
as:
<!DOCTYPE html>
<html lang="en"></html>
<head>
<meta charset="UTF-8"/>
<title>Document</title>
</head>
<body></body>
so the <html>
node is not enclosing the <head>
and <body>
Just installed the newest version of Emmet on Brackets 39, and I can't seem to expand any code. I used to just use TAB in css, but nothing. Has this behavior changed?
I checked and unchecked the option to expand with tab in the preferences, with no change at all.
Thanks in advance (:
Cannot assign Ctrl-Shift-Up to io.emmet.increment_number_by_1. It is already assigned to edit.lineUp
Cannot assign Ctrl-Shift-Down to io.emmet.decrement_number_by_1. It is already assigned to edit.lineDown
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
When typing:
// Load dependent modules
var AppInit = require();
ProjectManager = require("project/ProjectManager");
position your cursor after AppInit an hit the TAB key
Result:
// Load dependent modules
var <AppInit></AppInit> = require();
ProjectManager = require("project/ProjectManager");
Expected:
// Load dependent modules
var AppInit = require();
ProjectManager = require("project/ProjectManager");
While working with HTML in a .php file, the tab key don't Expand the Emmet abbreviations.
Anyone else ran into this issue ?
i followed up this workaround but with no luck
i am using the latest version of brackets, but it behave the same with the previous one.
thank you.
on windows, emmet's shortcut to move to the next edit point in text (ctrl + alt + right/left arrow) is the same as that to flip the screen. for this reason, it doesn't work and i have to keep selecting it from the menu (a huge pain). what's the best way to deal with this?
After installing Emmet,
Ctrl + Alt + R, open the "quick open folders list",
Press enter only to add a newline in editor.
But Shift + Enter is working.
I submitted a PR to CodeMirror for linked mode support codemirror/codemirror5#2327. Demo: jasonsanjose.github.io/demo/linkedmode/CodeMirror2/demo/linkedmode.html.
@sergeche It's still VERY early and I'm discussing with @marijnh on how to proceed. I just wanted to see what this Emmet extension would need to fully support tabstops. At the moment, tabstop sequence is based on the offset in the document, there isn't support yet for predefining the sequence.
I'm still brainstorming ideas, but it would be nice if linked mode had built-in support for the tabstop syntax $1
, ${1}
and ${1:placeholder}
.
When you hit Ctrl+Shift+A or select Wrap with Abbreviations from the Emmet window, the assocaited dialog opens, but the focus is on the OK button rather than the textbox to start entering the abbreviation.
Suggest the focus be on the textbox and not the button.
"wrap_with_abbreviation": "Shift-Ctrl-A",
Wrap with abbreviation is not focused in input, it is on Button "Ok", after Shift-Ctrl-A, there is need to click in input area and after it write the abbrevation.
Hi,
As part of our work to implement multiple selection functionality in Brackets, we need to add a few keyboard shortcuts for new commands. Unfortunately, a number of these shortcuts conflict with Emmet shortcuts.
If it's possible to change any of these shortcuts that are important for your users, that would be great. Otherwise, you can unregister the default Brackets shortcuts using KeyBindingManager.removeBinding()
before registering your own, but that means users wouldn't be able to access the Brackets functionality that uses these shortcuts.
Eventually we'll have configurable shortcuts so this won't be as much of an issue, but we just wanted to give you a heads-up. The new shortcuts will likely be added in Release 38, which should come out in a month or so.
The specific shortcuts that will conflict with existing Emmet shortcuts are:
Of these, I'd say Ctrl-Alt-L is probably the least important to worry about. Ctrl-B/Ctrl-Shift-B are probably the most useful, followed by Shift-Alt-Up/Down.
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/3981897-shortcuts-being-taken-by-brackets-core?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).I have configured an extension folder but it doesn't work/load and I'm not getting any error on the console mode that might be related to that.
Has someone manage to got it working in Linux/Ubuntu?
I'm trying to use: https://github.com/spirallab-org/emmet-foundation/
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
Hi.
My brackets: sprint 33 build experimental 0.33.0-10188 (On branch sprint-33-hotfix,sprint-33-hotfix b4c74d953) (taken directly from brackets.io as a deb for ubuntu 12.04)
Let's say I have a code
<div class="my-class">
I mark it, press ctrl-alt-A, fill the box with div.wrap and I get:
<div class="wrap">
<div class="my-class"></div>|<div class="my-class"></div>
</div>
With the cursor in the place of |
Greetings and thanks for emmet, it IS game changing tool :)
Adam
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
For personal preferences, I usually use soft tabs with 4 spaces instead of 2, as most people seems to be using now. Whenever I try to implement some code to my file, I always tried to clean it up so it has the proper identations as I have always been using.
But one day, I ran across this bug on Brackets which seems to only affect me if I'm using Emmet. Usually Brackets auto-adjusts the indentations while using soft tabs, but on some cases it doesn't seem to do it when Emmet is installed.
Not sure if I could explain it clearly, so I'll just attach some GIFs to demonstrate it.
Expected behaviour:
Current behaviour:
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/3981896-emmet-changes-the-soft-tabs-behaviour-for-brackets?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F311111&utm_medium=issues&utm_source=github).Sometimes Emmet interferes with other plugins, need to add menu item to toggle Emmet activity
For me at least, the shortcuts and the menu actions don't do anything.
I found this error in the developer console:
32 times - Uncaught TypeError: Object # has no method 'compoundChange' ........./Brackets/extensions/user/emmet/main.js:1
As mentioned in #37, we're adding multiple cursors/selections to Brackets in Sprint 38. I'm not sure if Emmet generally handles multiple selections in other editors, but it seems like it would be useful to make it do so.
For general info on how to make edits work with multiple selections in Brackets, please see Changes to Editor selection APIs and Performing edits on multiple selections. Also, if you do start taking advantage of these APIs, please make sure to mark your new version as requiring sprint 38 by setting "engines": { "brackets" : ">=0.38.0" }
in your extension's package.json
.
Thanks!
"increment_number_by_1": "Ctrl-Up",
"decrement_number_by_1": "Ctrl-Down"
The Shortcusts are not working, before updating the Brackets, they were working great.
This is only jade
specific behaviour:
input:radio
should produce (as the cheat sheet says [http://docs.emmet.io/cheat-sheet/]):
input(type="radio", name="")
instead it is producing:
input#(type="radio", name="")
So the #
is making the compiling from jade
problematically (tested here: http://jade-lang.com/demo/ : input is self closing and should not have content.
).
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
It is "insert_formatted_line_break": "Enter" that make Code Hints of the Brackets don't work well,because the “Enter" key is used on the selection of the Code Hinting.
THE END, THANK YOU FOR YOUR GRAET WORKS!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.