diagnostics.js 746 B

123456789101112131415161718
  1. "use strict";
  2. /**
  3. * @license
  4. * Copyright Google LLC All Rights Reserved.
  5. *
  6. * Use of this source code is governed by an MIT-style license that can be
  7. * found in the LICENSE file at https://angular.dev/license
  8. */
  9. Object.defineProperty(exports, "__esModule", { value: true });
  10. exports.formatDiagnostics = formatDiagnostics;
  11. const ts = require("typescript");
  12. const virtual_host_1 = require("./virtual-host");
  13. /** Formats the specified diagnostics with respect to the given file system. */
  14. function formatDiagnostics(diagnostics, fileSystem) {
  15. const formatHost = (0, virtual_host_1.createFormatDiagnosticHost)(fileSystem);
  16. return ts.formatDiagnosticsWithColorAndContext(diagnostics, formatHost);
  17. }
  18. //# sourceMappingURL=diagnostics.js.map