{"id":15662662,"url":"https://github.com/florinpatrascu/vscode-elixir-snippets","last_synced_at":"2025-10-10T14:03:33.822Z","repository":{"id":26301474,"uuid":"107876697","full_name":"florinpatrascu/vscode-elixir-snippets","owner":"florinpatrascu","description":"Elixir code snippets for VS Code","archived":false,"fork":false,"pushed_at":"2024-05-02T01:38:39.000Z","size":88,"stargazers_count":20,"open_issues_count":1,"forks_count":14,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-30T08:12:53.728Z","etag":null,"topics":["editor-plugin","elixir","snippets","vscode","vscode-elixir-snippets"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/florinpatrascu.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"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}},"created_at":"2017-10-22T15:10:05.000Z","updated_at":"2024-10-01T06:22:01.000Z","dependencies_parsed_at":"2024-05-02T02:52:59.266Z","dependency_job_id":"a716f9ed-4a8d-4c90-8408-a6f5d3acd396","html_url":"https://github.com/florinpatrascu/vscode-elixir-snippets","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/florinpatrascu%2Fvscode-elixir-snippets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/florinpatrascu%2Fvscode-elixir-snippets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/florinpatrascu%2Fvscode-elixir-snippets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/florinpatrascu%2Fvscode-elixir-snippets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/florinpatrascu","download_url":"https://codeload.github.com/florinpatrascu/vscode-elixir-snippets/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251666338,"owners_count":21624295,"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":["editor-plugin","elixir","snippets","vscode","vscode-elixir-snippets"],"created_at":"2024-10-03T13:33:53.731Z","updated_at":"2025-10-10T14:03:28.803Z","avatar_url":"https://github.com/florinpatrascu.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Elixir code snippets for VS Code\n\nGraciously borrowed all the snippets from the [TextMate bundle for Elixir](https://github.com/elixir-editors/elixir-tmbundle) and refactored them to work with VS Code.\n\n## Snippets\n\n| prefix             | description                                                                                              |\n| ------------------ | -------------------------------------------------------------------------------------------------------- |\n| case               | case                                                                                                     |\n| cond               | cond                                                                                                     |\n| def                | def                                                                                                      |\n| df                 | def (one line)                                                                                           |\n| defc               | defcallback                                                                                              |\n| defd               | defdelegate                                                                                              |\n| defe               | defexception                                                                                             |\n| defi               | defimpl                                                                                                  |\n| dmod               | defmodule                                                                                                |\n| defmc              | defmacrocallback                                                                                         |\n| defmp              | defmacrop                                                                                                |\n| describe           | describe \"..\" do ..                                                                                      |\n| dmac               | defmacro                                                                                                 |\n| defp               | defp                                                                                                     |\n| defpro             | defprotocol                                                                                              |\n| defs               | defstruct                                                                                                |\n| do                 | do                                                                                                       |\n| doc                | doc                                                                                                      |\n| ee                 | embed_eex                                                                                                |\n| ok                 | {:ok, ..} ...                                                                                            |\n| err                | {:error, ..} ...                                                                                         |\n| oke                | {:ok, ..} = ...                                                                                          |\n| erre               | {:error, ..} = ...                                                                                       |\n| trc                | try do catch                                                                                             |\n| exu, ex_unit       | ExUnit template                                                                                          |\n| trr                | try do rescue (everything!)                                                                              |\n| fn                 | fn                                                                                                       |\n| for                | for                                                                                                      |\n| fori               | for into                                                                                                 |\n| if                 | if                                                                                                       |\n| ife                | if else                                                                                                  |\n| ife:               | if else (one line)                                                                                       |\n| if:                | if (one line)                                                                                            |\n| imp                | import                                                                                                   |\n| i                  | inspect                                                                                                  |\n| ii                 | IO.inspect                                                                                               |\n| iib                | IO.inspect(binding(), module:line)                                                                       |\n| iil                | IO.inspect(label: ..)                                                                                    |\n| iill               | IO.inspect with label incl. the line number                                                              |\n| iins               | `IO.inspect` with a label containing relative path and line number. Label string can easily be discarded |\n| ist                | `IO.inspect` the current stacktrace                                                                      |\n| iip                | pipe to IO.inspect(module:line)                                                                          |\n| ip                 | IO.puts( ..)                                                                                             |\n| p                  | the pipeline operator                                                                                    |\n| pry                | IEx.pry                                                                                                  |\n| %                  | map/struct                                                                                               |\n| mdoc               | moduledoc                                                                                                |\n| mfs                | map from struct                                                                                          |\n| mp                 | Map.put/3 - puts the given value under key in map                                                        |\n| mpn                | Map.put_new/3 - puts the given value under key unless the entry key already exists in map                |\n| msan               | sanitize a Map by dropping some of its keys                                                              |\n| pe                 | print_eex                                                                                                |\n| rec                | receive                                                                                                  |\n| req                | require                                                                                                  |\n| test               | test \"..\" do ..                                                                                          |\n| testc              | test \"..\", %{..} do ..                                                                                   |\n| unless             | unless                                                                                                   |\n| unlesse            | unless else                                                                                              |\n| unlesse:           | unless else (one line)                                                                                   |\n| unless:            | unless (one line)                                                                                        |\n| supervisor         | OTP Supervisor module                                                                                    |\n| gen_server         | OTP GenServer module                                                                                     |\n| dynamic_supervisor | Elixir DynamicSupervisor module                                                                          |\n| wt                 | with .. do ..                                                                                            |\n| wte                | with .. do .. else ..                                                                                    |\n\n## Quick setup\n\nInstall it from: [florinpatrascu.vscode-elixir-snippets](https://marketplace.visualstudio.com/items?itemName=florinpatrascu.vscode-elixir-snippets)\n\nOr if you want to contribute with updates:\n\n```sh\n\ngit clone https://github.com/florinpatrascu/vscode-elixir-snippets.git\n```\n\nAnd copy the `vscode-elixir-snippets` folder into the `\u003cuser home\u003e/.vscode/extensions` folder. Restart Code.\n\n**Enjoy!**\n\n## License\n\n[MIT](LICENSE) License\n\nCopyright (c) 2017-2024 Florin T. PATRASCU\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflorinpatrascu%2Fvscode-elixir-snippets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflorinpatrascu%2Fvscode-elixir-snippets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflorinpatrascu%2Fvscode-elixir-snippets/lists"}