GithubHelp home page GithubHelp logo

mawkler / friendly-snippets Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rafamadriz/friendly-snippets

1.0 2.0 1.0 6.2 MB

Set of preconfigured snippets for different languages.

License: MIT License

friendly-snippets's Introduction

In this fork I've modified some of the snippets more to my liking, including making LaTeX snippet prefixes more verbose, and adding some global ones.


Friendly Snippets

Snippets collection for a set of different programming languages for faster development.

The only goal is to have one community driven repository for all kinds of snippets in all programming languages, this way you can have it all in one place.

Usage

This collection of snippets should work with any plugin that supports loading vscode snippets. Like for example:

Add snippets from a framework to a filetype.

There's extra snippets included in this repo but they are not added by default, since it would be irrelevant for people not using those frameworks. See snippets/frameworks

For example: if you want to add rails snippets to ruby.

With LuaSnip:

require'luasnip'.filetype_extend("ruby", {"rails"})

This method is going to work globally on all open buffers with ruby filetype. Alternatively you can do set filetype=ruby.rails so it only works on a specific buffer, but this is going to mess up with syntax highlighting.

With vim-vsnip:

let g:vsnip_filetypes.ruby = ['rails']

For more info related to this change see #88

Install

Use your plugin manager of choice, e.g.

-- Packer
use "rafamadriz/friendly-snippets"

-- Plug
Plug 'rafamadriz/friendly-snippets'

-- If you're using coc.nvim, you can use:
CocInstall https://github.com/rafamadriz/friendly-snippets@main

HTML

HTML gif

JS

JS gif

NOTE: Using nvim-compe with vim-vsnip on the videos.

TODO

  • Add all included snippets to the Wiki.

Thanks to all contributors

Credits

A good portion of the snippets have been forked from the following repositories:

friendly-snippets's People

Contributors

adrianocorrea avatar arrow-x avatar askfiy avatar aspeddro avatar bobbyrahmanda13 avatar bradsherman avatar bryant-the-coder avatar cinuor1 avatar cryptomilk avatar daniel-vera-g avatar davidbloss avatar djuan33 avatar eirabben avatar jeroenbourgois avatar jim-at-jibba avatar karyanayandi avatar kedap avatar mawkler avatar mohammedzeglam-pg avatar okelleydevelopment avatar ourigen avatar premell avatar rafamadriz avatar shubham-cpp avatar tarkin88 avatar wang-borong avatar willianba avatar winston0410 avatar yorik1984 avatar zweisamkeiten avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.