Skip to content

CSullivan102/vscode-hack

 
 

Repository files navigation

Hack for Visual Studio Code

Build Status

This extension adds rich Hack language & HHVM support to Visual Studio Code. Visit http://hacklang.org to get started with Hack.

It is published in the Visual Studio Marketplace here. To install, search for "Hack" in the VS Code extensions tab or run the following command (⌘+P): ext install vscode-hack.

NOTE: This is a very early preview release.

Features

  • Type Checking
  • Autocomplete
  • Hover Hints
  • Document Symbol Outline
  • Workspace Symbol Search
  • Document Formatting
  • Go To/Peek Definition
  • Find All References
  • Hack Coverage Check

Hack for Visual Studio Code

Requirements

This extension is supported on Linux and Mac OS X 10.10 onwards (see HHVM compatibility). The latest versions of Hack typechecking tools (hh_client and hh_server) are required on the local machine. The workspace should have a .hhconfig file at its root.

Configuration

This extension adds the following Visual Studio Code settings. These can be set in user preferences (⌘+,) or workspace settings (.vscode/settings.json).

  • hack.clientPath: Absolute path to the hh_client executable. This can be left empty if hh_client is already in your environment $PATH.

Issues

Please file all bugs, issues, feature requests etc. at the GitHub issues page.

Current known issues:

  • (#1, Microsoft/vscode#10915) The editor may not select the Hack language mode for .php files even if they start with <?hh. To get around this, either manually select "Hack" as the file language from the selector on the bottom right of the screen, or configure your project workspace to open all .php files in Hack mode by adding the following to your workspace settings:
    "files.associations": {
        "*.php": "hack"
    }

Contributing

There are lots of ways to help! You can file new bugs and feature requests, or fix a pending one. To contribute to the source code, fork the repository on GitHub and create a pull request.

Changelog

Please see the list of recent releases and features added.

License

The source code for this extension is available at https://github.com/PranayAgarwal/vscode-hack and is licenced under the MIT license.

About

Hack language support for Visual Studio Code.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 100.0%