Files
test-repo/tests_integration/plugins/extensions/plugin.js
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

25 lines
435 B
JavaScript
Raw Normal View History

"use strict";
2020-09-18 14:05:29 +08:00
const prettier = require("prettier-local");
2020-01-14 23:30:18 +08:00
const { concat } = prettier.doc.builders;
module.exports = {
languages: [
{
name: "foo",
parsers: ["foo-parser"],
extensions: [".foo"]
}
],
parsers: {
"foo-parser": {
parse: text => ({ text }),
astFormat: "foo-ast"
}
},
printers: {
"foo-ast": {
print: path => concat(["!", path.getValue().text])
}
}
};