UNPKG

@odata2ts/odata2ts

Version:

Flexible generator to produce various TypeScript artefacts (from simple model interfaces to complete odata clients) from OData metadata files

39 lines 988 B
import { __awaiter } from "tslib"; import { BaseFormatter } from "./BaseFormatter.js"; /** * Prettier formatter. * * NOTE: Should be created like this => const formatter = await new NoopFormatter("./test.ts").init(); * * @export * @class NoopFormatter * @extends {Formatter} */ export class NoopFormatter extends BaseFormatter { /** * Initializes the formatter. * * @abstract * @returns {Promise<Formatter>} Initialized formatter * @memberof Formatter */ init() { return __awaiter(this, void 0, void 0, function* () { return this; }); } /** * Formats a given source code. * * @abstract * @param {string} source Source code to format * @returns {string} Formatted source code * @memberof Formatter */ format(source) { return __awaiter(this, void 0, void 0, function* () { return source; }); } } //# sourceMappingURL=NoopFormatter.js.map