prettier-plugin-blade-volt
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published
Prettier PHP

Prettier Blade Plugin

GitHub Workflow Status npm version

This plugin has been https://github.com/shufo/prettier-plugin-blade extended for use with Livewire Volt.

The original functionality is retained, with the addition of the option addPrettierIgnoreForVolt.

By setting this option to true, the <?php start tag and the closing tag ? > before and after <! -- prettier-ignore-start --> and <! -- prettier-ignore-end --> before and after the closing tag `? This allows you to exclude prettier formatting between php tags in the blade.

Installation

npm install --save-dev @nxsdev/rettier-plugin-blade-volt

# yarn
yarn add -D @nxsdev/rettier-plugin-blade-volt

# pnpm
pnpm add -D @nxsdev/rettier-plugin-blade-volt

then, add in your Prettier configuration:

{
  "plugins": ["@nxsdev/prettier-plugin-blade-volt"],
  "overrides": [
    {
      "files": ["*.blade.php"],
      "options": {
        "parser": "blade",
        "tabWidth": 4,
        "addPrettierIgnoreForVolt": true
      }
    }
  ]
}

Since the rest is basically the same, please refer to this GitHub.

https://github.com/shufo/prettier-plugin-blade

Package Sidebar

Install

npm i prettier-plugin-blade-volt

Weekly Downloads

4

Version

0.1.0

License

MIT

Unpacked Size

23.9 kB

Total Files

13

Last publish

Collaborators

  • nxsdev