Giter Club home page Giter Club logo

highlight.lua's Introduction

Highlight.lua - Neovim

A Dynamic Syntax Highlighter Using TreeSitter Written In Lua

This plugins aims at making syntax highlighting in neovim better.
It uses neovim's treesitter api to provide color definition for languages that have available parsers.
The main goal is to provide a solid example on how to use this library.
It can be used by those who need better syntax coloring in their neovim environment.

Notice

  • Requires neovim v0.5
  • Is usable in the current state only to test and experiment
  • Only js filetypes are supported ATM
  • The plugin is under heavy development, it might change a lot or break things.
  • Even though its only to experiment while the neovim team is working on a better api, i still wish people to see what can be done with the treesitter API

Installing

With plug: Plug 'kyazdani42/highlight.lua'

You can install parsers running :InstallTSParser LANGUAGE. Only javascript is available at the moment.
The command does not work on windows and might not work on every OS. It depends on git and gcc.

Screenshot

alt text

TODO

  • refactor using query based highlight (.scm files are ready)
  • option / command to disable the plugin (provide detach function)
  • should provide a better default colorscheme in case neovim terminal colors are not set
  • option to disable some languages
  • better filetype handling
  • provide docs

TODO Performance

  • highlighting should not block the UI on large files.
  • updating the buffer should not update the whole file

Supported Languages

language support
Javascript Partial (60%)
Jsx None
Typescript/tsx None
Rust None
Lua None
C None
C++ None
Python None
Ruby None
Go None
Html None
Css None
Php None

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.