Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QUESTION] How to enable haml support in vscode? #568

Closed
aesyondu opened this issue May 23, 2020 · 1 comment
Closed

[QUESTION] How to enable haml support in vscode? #568

aesyondu opened this issue May 23, 2020 · 1 comment

Comments

@aesyondu
Copy link

aesyondu commented May 23, 2020

Metadata

  • Ruby version: 2.3.1
  • @prettier/plugin-ruby version: ^0.18.2 (Installed inside ~/home/.vscode/extensions/esbenp.prettier-vscode-4.7.0/)

Input

Hi, I would like to try this out, how do I use it in vscode?

I followed the install guide here:
#113 (comment)

Then tried it on a test.my.haml file:

%div
  "blast"

With the following output:

["INFO" - 5:21:19 PM] Formatting /path/to/project/test.my.haml
["INFO" - 5:21:19 PM] Using ignore file (if present) at /path/to/project/.prettierignore
["INFO" - 5:21:19 PM] Using bundled version of prettier.
["INFO" - 5:21:19 PM] File Info:
{
  "ignored": false,
  "inferredParser": "haml"
}
["INFO" - 5:21:19 PM] No local configuration (i.e. .prettierrc or .editorconfig) detected, falling back to VS Code configuration
["INFO" - 5:21:19 PM] Prettier Options:
{
  "arrowParens": "always",
  "bracketSpacing": true,
  "endOfLine": "lf",
  "htmlWhitespaceSensitivity": "css",
  "insertPragma": false,
  "jsxBracketSameLine": false,
  "jsxSingleQuote": false,
  "printWidth": 80,
  "proseWrap": "preserve",
  "quoteProps": "as-needed",
  "requirePragma": false,
  "semi": true,
  "singleQuote": false,
  "tabWidth": 2,
  "trailingComma": "es5",
  "useTabs": false,
  "vueIndentScriptAndStyle": false,
  "filepath": "/path/to/project/test.my.haml",
  "parser": "haml"
}
["ERROR" - 5:21:19 PM] Error formatting document.
["INFO" - 5:21:19 PM] Formatting completed in 229.813886ms.
@kddnewton
Copy link
Member

Hi there! I've extracted the HAML plugin to its own JS package in @prettier/plugin-haml. It now lives over here: https://github.com/prettier/plugin-haml. Please try out that package and let me know if you experience trouble over on that repo. Thanks!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants