{"id":13399307,"url":"https://github.com/mattn/emmet-vim","last_synced_at":"2025-04-08T21:18:54.002Z","repository":{"id":814733,"uuid":"524305","full_name":"mattn/emmet-vim","owner":"mattn","description":"emmet for vim: http://emmet.io/","archived":false,"fork":false,"pushed_at":"2024-08-10T02:07:49.000Z","size":1332,"stargazers_count":6433,"open_issues_count":132,"forks_count":411,"subscribers_count":107,"default_branch":"master","last_synced_at":"2024-10-29T14:55:57.226Z","etag":null,"topics":["css","emmet","html","javascript","vim"],"latest_commit_sha":null,"homepage":"http://mattn.github.io/emmet-vim","language":"Vim Script","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"steveukx/git-js","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mattn.png","metadata":{"files":{"readme":"README.mkd","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"mattn","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2010-02-18T13:29:20.000Z","updated_at":"2024-10-29T14:47:34.000Z","dependencies_parsed_at":"2024-11-08T03:33:49.903Z","dependency_job_id":"33c592fd-926f-43d9-9ae9-b2a5e4de0938","html_url":"https://github.com/mattn/emmet-vim","commit_stats":{"total_commits":986,"total_committers":87,"mean_commits":"11.333333333333334","dds":"0.12981744421906694","last_synced_commit":"6c511a8d7d2863066f32e25543e2bb99d505172c"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Femmet-vim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Femmet-vim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Femmet-vim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Femmet-vim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mattn","download_url":"https://codeload.github.com/mattn/emmet-vim/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247426993,"owners_count":20937199,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["css","emmet","html","javascript","vim"],"created_at":"2024-07-30T19:00:36.169Z","updated_at":"2025-04-08T21:18:53.979Z","avatar_url":"https://github.com/mattn.png","language":"Vim Script","readme":"# Emmet-vim\n\n\n[![Build Status](https://travis-ci.org/mattn/emmet-vim.svg?branch=master)](https://travis-ci.org/mattn/emmet-vim)\n\n[emmet-vim](https://mattn.github.io/emmet-vim/) is a vim plug-in\nwhich provides support for expanding abbreviations similar to\n[emmet](http://emmet.io/).\n\n![screenshot](https://raw.githubusercontent.com/mattn/emmet-vim/master/doc/screenshot.gif)\n\n## Installation\n\n[Download zip file](http://www.vim.org/scripts/script.php?script_id=2981):\n\n```sh\ncd ~/.vim\nunzip emmet-vim.zip\n```\n\nTo install using [pathogen.vim](https://github.com/tpope/vim-pathogen):\n\n```sh\ngit clone https://github.com/mattn/emmet-vim.git ~/.vim/bundle/emmet-vim\n```\n\nTo install using [Vundle](https://github.com/gmarik/vundle):\n\n```vim\n\" add this line to your .vimrc file\nPlugin 'mattn/emmet-vim'\n```\n\nTo install using [Vim-Plug](https://github.com/junegunn/vim-plug):\n\n```vim\n\" add this line to your .vimrc file\nPlug 'mattn/emmet-vim'\n```\n\nTo checkout the source from repository:\n\n```sh\ncd ~/.vim/bundle\ngit clone https://github.com/mattn/emmet-vim.git\n```\n\nor:\n\n```sh\ngit clone https://github.com/mattn/emmet-vim.git\ncd emmet-vim\ncp plugin/emmet.vim ~/.vim/plugin/\ncp autoload/emmet.vim ~/.vim/autoload/\ncp -a autoload/emmet ~/.vim/autoload/\n```\n\n\n## Quick Tutorial\n\nOpen or create a New File:\n\n```sh\nvim index.html\n```\n\nType (\"\\_\" is the cursor position):\n\n    html:5_\n\nThen type `\u003cc-y\u003e,` (\u003ckbd\u003eCtrl\u003c/kbd\u003e\u003ckbd\u003ey\u003c/kbd\u003e\u003ckbd\u003e,\u003c/kbd\u003e), and you should see:\n\n```html\n\u003c!DOCTYPE HTML\u003e\n\u003chtml lang=\"en\"\u003e\n\u003chead\u003e\n\t\u003cmeta charset=\"UTF-8\"\u003e\n\t\u003ctitle\u003e\u003c/title\u003e\n\u003c/head\u003e\n\u003cbody\u003e\n\t_\n\u003c/body\u003e\n\u003c/html\u003e\n```\n\n[More Tutorials](https://raw.githubusercontent.com/mattn/emmet-vim/master/TUTORIAL)\n\n\n## Enable in different mode\n\nIf you don't want to enable emmet in all modes,\nyou can use set these options in `vimrc`:\n\n```vim\nlet g:user_emmet_mode='n'    \"only enable normal mode functions.\nlet g:user_emmet_mode='inv'  \"enable all functions, which is equal to\nlet g:user_emmet_mode='a'    \"enable all function in all mode.\n```\n\n## Enable just for html/css\n\n```vim\nlet g:user_emmet_install_global = 0\nautocmd FileType html,css EmmetInstall\n```\n\n## Redefine trigger key\nTo remap the default `\u003cC-Y\u003e` leader:\n\n```vim\nlet g:user_emmet_leader_key='\u003cC-Z\u003e'\n```\n\nNote that the trailing `,` still needs to be entered, so the new keymap would be `\u003cC-Z\u003e,`.\n\n## Adding custom snippets\nIf you have installed the [web-api](https://github.com/mattn/webapi-vim) for **emmet-vim** you can also add your own snippets using a custom **snippets.json** file.\n\nOnce you have installed the [web-api](https://github.com/mattn/webapi-vim) add this line to your **.vimrc**:\n```\nlet g:user_emmet_settings = webapi#json#decode(join(readfile(expand('~/.snippets_custom.json')), \"\\n\"))\n```\nYou can change the **path** to your **snippets_custom.json** according to your preferences.\n\n[Here](http://docs.emmet.io/customization/snippets/) you can find instructions about creating your customized **snippets.json** file.\n\n## Snippet to add meta tag for responsiveness\nUpdate this in your .vimrc file.\n\n\n\tlet g:user_emmet_settings = {\n\t\\  'variables': {'lang': 'ja'},\n\t\\  'html': {\n\t\\    'default_attributes': {\n\t\\      'option': {'value': v:null},\n\t\\      'textarea': {'id': v:null, 'name': v:null, 'cols': 10, 'rows': 10},\n\t\\    },\n\t\\    'snippets': {\n\t\\      'html:5': \"\u003c!DOCTYPE html\u003e\\n\"\n\t\\              .\"\u003chtml lang=\\\"${lang}\\\"\u003e\\n\"\n\t\\              .\"\u003chead\u003e\\n\"\n\t\\              .\"\\t\u003cmeta charset=\\\"${charset}\\\"\u003e\\n\"\n\t\\              .\"\\t\u003ctitle\u003e\u003c/title\u003e\\n\"\n\t\\              .\"\\t\u003cmeta name=\\\"viewport\\\" content=\\\"width=device-width, initial-scale=1.0\\\"\u003e\\n\"\n\t\\              .\"\u003c/head\u003e\\n\"\n\t\\              .\"\u003cbody\u003e\\n\\t${child}|\\n\u003c/body\u003e\\n\"\n\t\\              .\"\u003c/html\u003e\",\n\t\\    },\n\t\\  },\n\t\\}\n\n\n## Project Authors\n\n[Yasuhiro Matsumoto](http://mattn.kaoriya.net/)\n\n## FAQ\n\n* Pressing ctrl+y+, doesn't work\n\n  Probably you set `timeoutlen=0`. Most of Vim plugins which using key-mappings does not work with `timeoutlen=0`.\n\n## Links\n\n### Emmet official site:\n\n* \u003chttp://emmet.io/\u003e\n\n### zen-coding official site:\n\n* \u003chttp://code.google.com/p/zen-coding/\u003e\n\n### emmet.vim:\n\n* \u003chttps://mattn.github.io/emmet-vim/\u003e\n\n### development repository:\n\n* \u003chttps://github.com/mattn/emmet-vim\u003e\n\n### my blog posts about zencoding-vim:\n\n* \u003chttp://mattn.kaoriya.net/software/vim/20100222103327.htm\u003e\n\n* \u003chttp://mattn.kaoriya.net/software/vim/20100306021632.htm\u003e\n\n### Japanese blog posts about zencoding-vim:\n\n* \u003chttp://d.hatena.ne.jp/idesaku/20100424/1272092255\u003e\n\n* \u003chttp://d.hatena.ne.jp/griefworker/20110118/vim_zen_coding\u003e\n\n* \u003chttp://d.hatena.ne.jp/sakurako_s/20110126/1295988873\u003e\n\n* \u003chttp://looxu.blogspot.jp/2010/02/zencodingvimhtml.html\u003e\n\n### A Chinese translation of the tutorial:\n\n* \u003chttp://www.zfanw.com/blog/zencoding-vim-tutorial-chinese.html\u003e\n\n","funding_links":["https://github.com/sponsors/mattn"],"categories":["Vim Script","Vim script","Editor plugins","VimL","Plugins / Themes / Dependencies"],"sub_categories":["Vim/Neovim"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattn%2Femmet-vim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmattn%2Femmet-vim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattn%2Femmet-vim/lists"}