@putout/plugin-montag

2.0.0 • Public • Published

@putout/plugin-apply-montag NPM version

Format multiline strings using tagged templates, instead of putting all lines into an array and joining to a string.

(c) Montag

🐊Putout plugin adds ability to apply Montag. Renamed to @putout/plugin-montag.

Install

npm i @putout/plugin-apply-montag

Rule

{
    "rules": {
        "montag/apply": "on",
        "montag/declare": "on"
    }
}

apply

Example of incorrect code

const a = [
    'hello',
    'world',
].join('\n');

Example of correct code

const a = montag`
    hello
    world
`;

declare

Example of incorrect code

const a = montag`
    hello
    world
`;

Example of correct code

import montag from 'montag';
const a = montag`
    hello
    world
`;

License

MIT

Package Sidebar

Install

npm i @putout/plugin-montag

Weekly Downloads

3,420

Version

2.0.0

License

MIT

Unpacked Size

5.13 kB

Total Files

6

Last publish

Collaborators

  • coderaiser