apeframework 0.0.0-dev.21 → 0.0.0-dev.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/{cipher → dist/cipher}/Cipher.d.ts +1 -1
  2. package/{cipher → dist/cipher}/Cipher.js +6 -6
  3. package/{cipher → dist/cipher}/errors/DecryptError.d.ts +1 -1
  4. package/{cipher → dist/cipher}/errors/DecryptError.js +1 -1
  5. package/{jwt → dist/cipher}/errors/SecretLengthError.d.ts +1 -1
  6. package/{cipher → dist/cipher}/errors/SecretLengthError.js +1 -1
  7. package/{cipher → dist/cipher}/validateSecretLength.d.ts +1 -1
  8. package/{cipher → dist/cipher}/validateSecretLength.js +2 -2
  9. package/{cli → dist/cli}/Command.d.ts +1 -1
  10. package/{cli → dist/cli}/getArgs.d.ts +1 -1
  11. package/{cli → dist/cli}/getArgs.js +1 -1
  12. package/{cli → dist/cli}/parseArgs.d.ts +1 -1
  13. package/{config → dist/config}/Properties.d.ts +1 -1
  14. package/{config → dist/config}/errors/FileReadError.d.ts +1 -1
  15. package/{config → dist/config}/errors/FileReadError.js +1 -1
  16. package/{config → dist/config}/errors/PropertyNameError.d.ts +1 -1
  17. package/{config → dist/config}/errors/PropertyNameError.js +1 -1
  18. package/{config → dist/config}/errors/PropertyParseError.d.ts +1 -1
  19. package/{config → dist/config}/errors/PropertyParseError.js +1 -1
  20. package/{config → dist/config}/getConfig.d.ts +4 -4
  21. package/{config → dist/config}/getConfig.js +4 -4
  22. package/{config → dist/config}/parseProperty.d.ts +1 -1
  23. package/{config → dist/config}/parseProperty.js +1 -1
  24. package/{config → dist/config}/readFile.js +1 -1
  25. package/{config → dist/config}/validatePropertyName.js +1 -1
  26. package/{env → dist/env}/errors/FileReadError.d.ts +1 -1
  27. package/{tls → dist/env}/errors/FileReadError.js +1 -1
  28. package/{env → dist/env}/getEnv.d.ts +1 -1
  29. package/{env → dist/env}/getEnv.js +1 -1
  30. package/{env → dist/env}/readFile.d.ts +1 -1
  31. package/{env → dist/env}/readFile.js +1 -1
  32. package/{jwt → dist/jwt}/Jwt.d.ts +2 -2
  33. package/{jwt → dist/jwt}/Jwt.js +1 -1
  34. package/{cipher → dist/jwt}/errors/SecretLengthError.d.ts +1 -1
  35. package/{jwt → dist/jwt}/errors/SecretLengthError.js +1 -1
  36. package/{jwt → dist/jwt}/validateSecretLength.d.ts +1 -1
  37. package/{jwt → dist/jwt}/validateSecretLength.js +2 -2
  38. package/{logger → dist/logger}/adapters/file/FileLogger.d.ts +2 -2
  39. package/{logger → dist/logger}/adapters/file/FileLogger.js +4 -4
  40. package/{logger → dist/logger}/adapters/file/errors/FileInitError.d.ts +1 -1
  41. package/{logger → dist/logger}/adapters/file/errors/FileInitError.js +1 -1
  42. package/{logger → dist/logger}/adapters/file/initFile.js +1 -1
  43. package/{logger → dist/logger}/adapters/noop/NoopLogger.d.ts +1 -1
  44. package/{logger → dist/logger}/adapters/noop/NoopLogger.js +1 -1
  45. package/{logger → dist/logger}/adapters/stdio/StdioLogger.d.ts +2 -2
  46. package/{logger → dist/logger}/adapters/stdio/StdioLogger.js +3 -3
  47. package/{mailer → dist/mailer}/Event.d.ts +2 -2
  48. package/{mailer → dist/mailer}/Mail.d.ts +4 -4
  49. package/{mailer → dist/mailer}/Mailer.d.ts +1 -1
  50. package/{mailer → dist/mailer}/Mailer.js +5 -5
  51. package/{mailer → dist/mailer}/adapters/noop/NoopMailer.d.ts +2 -2
  52. package/{mailer → dist/mailer}/adapters/noop/NoopMailer.js +1 -1
  53. package/{mailer → dist/mailer}/adapters/smtp/SmtpMailer.d.ts +3 -3
  54. package/{mailer → dist/mailer}/adapters/smtp/SmtpMailer.js +6 -6
  55. package/{mailer → dist/mailer}/adapters/smtp/getAddress.d.ts +1 -1
  56. package/{mailer → dist/mailer}/adapters/smtp/getAddresses.d.ts +1 -1
  57. package/{mailer → dist/mailer}/adapters/smtp/getAddresses.js +1 -1
  58. package/{mailer → dist/mailer}/adapters/smtp/getAttachments.d.ts +1 -1
  59. package/{mailer → dist/mailer}/errors/AddressEmailError.d.ts +1 -1
  60. package/{mailer → dist/mailer}/errors/AddressEmailError.js +1 -1
  61. package/{mailer → dist/mailer}/errors/EventAttachmentUrlError.d.ts +1 -1
  62. package/{mailer → dist/mailer}/errors/EventAttachmentUrlError.js +1 -1
  63. package/{mailer → dist/mailer}/errors/EventGeolocationError.d.ts +1 -1
  64. package/{mailer → dist/mailer}/errors/EventGeolocationError.js +1 -1
  65. package/{mailer → dist/mailer}/errors/EventUrlError.d.ts +1 -1
  66. package/{mailer → dist/mailer}/errors/EventUrlError.js +1 -1
  67. package/{mailer → dist/mailer}/errors/ListUrlError.d.ts +1 -1
  68. package/{mailer → dist/mailer}/errors/ListUrlError.js +1 -1
  69. package/{mailer → dist/mailer}/getIcalendar.d.ts +1 -1
  70. package/{mailer → dist/mailer}/validateAddressEmail.js +2 -2
  71. package/{mailer → dist/mailer}/validateEventAttachmentUrl.js +2 -2
  72. package/{mailer → dist/mailer}/validateEventGeolocation.js +2 -2
  73. package/{mailer → dist/mailer}/validateEventUrl.js +2 -2
  74. package/{mailer → dist/mailer}/validateListUrl.js +2 -2
  75. package/{parser → dist/parser}/errors/ParseError.d.ts +1 -1
  76. package/{parser → dist/parser}/errors/ParseError.js +1 -1
  77. package/dist/parser/factories/enum/createEnumParser.d.ts +6 -0
  78. package/{parser → dist/parser}/factories/enum/createEnumParser.js +1 -1
  79. package/{parser → dist/parser}/factories/unit/createUnitParser.d.ts +2 -2
  80. package/{parser → dist/parser}/factories/unit/createUnitParser.js +3 -3
  81. package/{parser → dist/parser}/parseBoolean.d.ts +1 -1
  82. package/{parser → dist/parser}/parseBoolean.js +1 -1
  83. package/dist/parser/parseBytes.d.ts +2 -0
  84. package/{parser → dist/parser}/parseBytes.js +1 -1
  85. package/{parser → dist/parser}/parseInteger.d.ts +1 -1
  86. package/{parser → dist/parser}/parseInteger.js +2 -2
  87. package/dist/parser/parseMilliseconds.d.ts +2 -0
  88. package/{parser → dist/parser}/parseMilliseconds.js +1 -1
  89. package/{parser → dist/parser}/parseNumber.d.ts +1 -1
  90. package/{parser → dist/parser}/parseNumber.js +1 -1
  91. package/{parser → dist/parser}/parseString.d.ts +1 -1
  92. package/{parser → dist/parser}/parseString.js +1 -1
  93. package/{pwd → dist/pwd}/Pwd.js +1 -1
  94. package/{pwd → dist/pwd}/errors/HashRoundsError.d.ts +1 -1
  95. package/{pwd → dist/pwd}/errors/HashRoundsError.js +1 -1
  96. package/{pwd → dist/pwd}/validateHashRounds.js +1 -1
  97. package/{server → dist/server}/Route.d.ts +3 -3
  98. package/{server → dist/server}/Server.d.ts +5 -5
  99. package/{server → dist/server}/Server.js +2 -2
  100. package/{server → dist/server}/getAjv.d.ts +1 -1
  101. package/{tls → dist/tls}/errors/FileReadError.d.ts +1 -1
  102. package/{env → dist/tls}/errors/FileReadError.js +1 -1
  103. package/{tls → dist/tls}/getTls.d.ts +1 -1
  104. package/{tls → dist/tls}/getTls.js +1 -1
  105. package/{tls → dist/tls}/readFile.js +1 -1
  106. package/package.json +632 -6
  107. package/parser/factories/enum/createEnumParser.d.ts +0 -6
  108. package/parser/parseBytes.d.ts +0 -2
  109. package/parser/parseMilliseconds.d.ts +0 -2
  110. /package/{cipher → dist/cipher}/Algorithm.d.ts +0 -0
  111. /package/{cipher → dist/cipher}/Algorithm.js +0 -0
  112. /package/{cli → dist/cli}/Args.d.ts +0 -0
  113. /package/{cli → dist/cli}/Args.js +0 -0
  114. /package/{cli → dist/cli}/Command.js +0 -0
  115. /package/{cli → dist/cli}/parseArgs.js +0 -0
  116. /package/{cli → dist/cli}/utils/exit.d.ts +0 -0
  117. /package/{cli → dist/cli}/utils/exit.js +0 -0
  118. /package/{cli → dist/cli}/utils/formatList.d.ts +0 -0
  119. /package/{cli → dist/cli}/utils/formatList.js +0 -0
  120. /package/{cli → dist/cli}/utils/formatTable.d.ts +0 -0
  121. /package/{cli → dist/cli}/utils/formatTable.js +0 -0
  122. /package/{cli → dist/cli}/utils/formatText.d.ts +0 -0
  123. /package/{cli → dist/cli}/utils/formatText.js +0 -0
  124. /package/{cli → dist/cli}/utils/print.d.ts +0 -0
  125. /package/{cli → dist/cli}/utils/print.js +0 -0
  126. /package/{cli → dist/cli}/utils/printLn.d.ts +0 -0
  127. /package/{cli → dist/cli}/utils/printLn.js +0 -0
  128. /package/{config → dist/config}/Config.d.ts +0 -0
  129. /package/{config → dist/config}/Config.js +0 -0
  130. /package/{config → dist/config}/Properties.js +0 -0
  131. /package/{config → dist/config}/getPropertyEnvVar.d.ts +0 -0
  132. /package/{config → dist/config}/getPropertyEnvVar.js +0 -0
  133. /package/{config → dist/config}/readFile.d.ts +0 -0
  134. /package/{config → dist/config}/validatePropertyName.d.ts +0 -0
  135. /package/{env → dist/env}/Env.d.ts +0 -0
  136. /package/{env → dist/env}/Env.js +0 -0
  137. /package/{error → dist/error}/BaseError.d.ts +0 -0
  138. /package/{error → dist/error}/BaseError.js +0 -0
  139. /package/{jwt → dist/jwt}/Algorithm.d.ts +0 -0
  140. /package/{jwt → dist/jwt}/Algorithm.js +0 -0
  141. /package/{jwt → dist/jwt}/Payload.d.ts +0 -0
  142. /package/{jwt → dist/jwt}/Payload.js +0 -0
  143. /package/{logger → dist/logger}/Level.d.ts +0 -0
  144. /package/{logger → dist/logger}/Level.js +0 -0
  145. /package/{logger → dist/logger}/Logger.d.ts +0 -0
  146. /package/{logger → dist/logger}/Logger.js +0 -0
  147. /package/{logger → dist/logger}/Severity.d.ts +0 -0
  148. /package/{logger → dist/logger}/Severity.js +0 -0
  149. /package/{logger → dist/logger}/adapters/file/initFile.d.ts +0 -0
  150. /package/{mailer → dist/mailer}/Address.d.ts +0 -0
  151. /package/{mailer → dist/mailer}/Address.js +0 -0
  152. /package/{mailer → dist/mailer}/Attachment.d.ts +0 -0
  153. /package/{mailer → dist/mailer}/Attachment.js +0 -0
  154. /package/{mailer → dist/mailer}/Event.js +0 -0
  155. /package/{mailer → dist/mailer}/List.d.ts +0 -0
  156. /package/{mailer → dist/mailer}/List.js +0 -0
  157. /package/{mailer → dist/mailer}/Location.d.ts +0 -0
  158. /package/{mailer → dist/mailer}/Location.js +0 -0
  159. /package/{mailer → dist/mailer}/Mail.js +0 -0
  160. /package/{mailer → dist/mailer}/Method.d.ts +0 -0
  161. /package/{mailer → dist/mailer}/Method.js +0 -0
  162. /package/{mailer → dist/mailer}/adapters/smtp/getAddress.js +0 -0
  163. /package/{mailer → dist/mailer}/adapters/smtp/getAttachments.js +0 -0
  164. /package/{mailer → dist/mailer}/getIcalendar.js +0 -0
  165. /package/{mailer → dist/mailer}/validateAddressEmail.d.ts +0 -0
  166. /package/{mailer → dist/mailer}/validateEventAttachmentUrl.d.ts +0 -0
  167. /package/{mailer → dist/mailer}/validateEventGeolocation.d.ts +0 -0
  168. /package/{mailer → dist/mailer}/validateEventUrl.d.ts +0 -0
  169. /package/{mailer → dist/mailer}/validateListUrl.d.ts +0 -0
  170. /package/{parser → dist/parser}/Parser.d.ts +0 -0
  171. /package/{parser → dist/parser}/Parser.js +0 -0
  172. /package/{parser → dist/parser}/factories/unit/Unit.d.ts +0 -0
  173. /package/{parser → dist/parser}/factories/unit/Unit.js +0 -0
  174. /package/{pwd → dist/pwd}/Pwd.d.ts +0 -0
  175. /package/{pwd → dist/pwd}/validateHashRounds.d.ts +0 -0
  176. /package/{server → dist/server}/ErrorHandler.d.ts +0 -0
  177. /package/{server → dist/server}/ErrorHandler.js +0 -0
  178. /package/{server → dist/server}/Format.d.ts +0 -0
  179. /package/{server → dist/server}/Format.js +0 -0
  180. /package/{server → dist/server}/Handler.d.ts +0 -0
  181. /package/{server → dist/server}/Handler.js +0 -0
  182. /package/{server → dist/server}/Method.d.ts +0 -0
  183. /package/{server → dist/server}/Method.js +0 -0
  184. /package/{server → dist/server}/OpenApiFormat.d.ts +0 -0
  185. /package/{server → dist/server}/OpenApiFormat.js +0 -0
  186. /package/{server → dist/server}/Route.js +0 -0
  187. /package/{server → dist/server}/Schema.d.ts +0 -0
  188. /package/{server → dist/server}/Schema.js +0 -0
  189. /package/{server → dist/server}/getAjv.js +0 -0
  190. /package/{tls → dist/tls}/Tls.d.ts +0 -0
  191. /package/{tls → dist/tls}/Tls.js +0 -0
  192. /package/{tls → dist/tls}/readFile.d.ts +0 -0
  193. /package/{utils → dist/utils}/getRandomHexString.d.ts +0 -0
  194. /package/{utils → dist/utils}/getRandomHexString.js +0 -0
  195. /package/{utils → dist/utils}/getTimestamp.d.ts +0 -0
  196. /package/{utils → dist/utils}/getTimestamp.js +0 -0
  197. /package/{utils → dist/utils}/isValidEmail.d.ts +0 -0
  198. /package/{utils → dist/utils}/isValidEmail.js +0 -0
  199. /package/{utils → dist/utils}/isValidGeolocation.d.ts +0 -0
  200. /package/{utils → dist/utils}/isValidGeolocation.js +0 -0
  201. /package/{utils → dist/utils}/isValidHexString.d.ts +0 -0
  202. /package/{utils → dist/utils}/isValidHexString.js +0 -0
  203. /package/{utils → dist/utils}/isValidIsoDate.d.ts +0 -0
  204. /package/{utils → dist/utils}/isValidIsoDate.js +0 -0
  205. /package/{utils → dist/utils}/isValidJwtToken.d.ts +0 -0
  206. /package/{utils → dist/utils}/isValidJwtToken.js +0 -0
  207. /package/{utils → dist/utils}/isValidUrl.d.ts +0 -0
  208. /package/{utils → dist/utils}/isValidUrl.js +0 -0
  209. /package/{utils → dist/utils}/isValidUuid.d.ts +0 -0
  210. /package/{utils → dist/utils}/isValidUuid.js +0 -0
  211. /package/{utils → dist/utils}/wait.d.ts +0 -0
  212. /package/{utils → dist/utils}/wait.js +0 -0
@@ -1,5 +1,5 @@
1
- import { isValidGeolocation } from 'utils/isValidGeolocation';
2
- import { EventGeolocationError } from './errors/EventGeolocationError';
1
+ import { isValidGeolocation } from '../utils/isValidGeolocation.js';
2
+ import { EventGeolocationError } from './errors/EventGeolocationError.js';
3
3
  const validateEventGeolocation = (latitude, longitude) => {
4
4
  if (!isValidGeolocation(latitude, longitude)) {
5
5
  throw new EventGeolocationError(latitude, longitude);
@@ -1,5 +1,5 @@
1
- import { isValidUrl } from 'utils/isValidUrl';
2
- import { EventUrlError } from './errors/EventUrlError';
1
+ import { isValidUrl } from '../utils/isValidUrl.js';
2
+ import { EventUrlError } from './errors/EventUrlError.js';
3
3
  const validateEventUrl = (url) => {
4
4
  if (!isValidUrl(url)) {
5
5
  throw new EventUrlError(url);
@@ -1,5 +1,5 @@
1
- import { isValidUrl } from 'utils/isValidUrl';
2
- import { ListUrlError } from './errors/ListUrlError';
1
+ import { isValidUrl } from '../utils/isValidUrl.js';
2
+ import { ListUrlError } from './errors/ListUrlError.js';
3
3
  const validateListUrl = (property, url) => {
4
4
  if (!isValidUrl(url)) {
5
5
  throw new ListUrlError(property, url);
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  declare class ParseError extends BaseError {
3
3
  constructor(type: string);
4
4
  }
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  class ParseError extends BaseError {
3
3
  constructor(type) {
4
4
  super(`failed parsing ${type}`);
@@ -0,0 +1,6 @@
1
+ import type { Parser } from '../../Parser.js';
2
+ declare const createEnumParser: <Enum extends Record<string, string | number>>(params: {
3
+ type: string;
4
+ enum: Enum;
5
+ }) => Parser<Enum[keyof Enum]>;
6
+ export { createEnumParser, };
@@ -1,4 +1,4 @@
1
- import { ParseError } from '../../errors/ParseError';
1
+ import { ParseError } from '../../errors/ParseError.js';
2
2
  const createEnumParser = (params) => {
3
3
  return (input) => {
4
4
  if (!Object.values(params.enum).includes(input)) {
@@ -1,5 +1,5 @@
1
- import type { Unit } from './Unit';
2
- import type { Parser } from '../../Parser';
1
+ import type { Unit } from './Unit.js';
2
+ import type { Parser } from '../../Parser.js';
3
3
  declare const createUnitParser: (params: {
4
4
  type: string;
5
5
  units: Unit[];
@@ -1,6 +1,6 @@
1
- import { ParseError } from '../../errors/ParseError';
2
- import { parseNumber } from '../../parseNumber';
3
- import { parseString } from '../../parseString';
1
+ import { ParseError } from '../../errors/ParseError.js';
2
+ import { parseNumber } from '../../parseNumber.js';
3
+ import { parseString } from '../../parseString.js';
4
4
  const createUnitParser = (params) => {
5
5
  return (input) => {
6
6
  let string;
@@ -1,3 +1,3 @@
1
- import type { Parser } from './Parser';
1
+ import type { Parser } from './Parser.js';
2
2
  declare const parseBoolean: Parser<boolean>;
3
3
  export { parseBoolean, };
@@ -1,4 +1,4 @@
1
- import { ParseError } from './errors/ParseError';
1
+ import { ParseError } from './errors/ParseError.js';
2
2
  const parseBoolean = (input) => {
3
3
  if ([
4
4
  true,
@@ -0,0 +1,2 @@
1
+ declare const parseBytes: import("./Parser.js").Parser<number>;
2
+ export { parseBytes, };
@@ -1,4 +1,4 @@
1
- import { createUnitParser } from './factories/unit/createUnitParser';
1
+ import { createUnitParser } from './factories/unit/createUnitParser.js';
2
2
  const parseBytes = createUnitParser({
3
3
  type: 'bytes',
4
4
  units: [
@@ -1,3 +1,3 @@
1
- import type { Parser } from './Parser';
1
+ import type { Parser } from './Parser.js';
2
2
  declare const parseInteger: Parser<number>;
3
3
  export { parseInteger, };
@@ -1,5 +1,5 @@
1
- import { ParseError } from './errors/ParseError';
2
- import { parseNumber } from './parseNumber';
1
+ import { ParseError } from './errors/ParseError.js';
2
+ import { parseNumber } from './parseNumber.js';
3
3
  const parseInteger = (input) => {
4
4
  let number;
5
5
  try {
@@ -0,0 +1,2 @@
1
+ declare const parseMilliseconds: import("./Parser.js").Parser<number>;
2
+ export { parseMilliseconds, };
@@ -1,4 +1,4 @@
1
- import { createUnitParser } from './factories/unit/createUnitParser';
1
+ import { createUnitParser } from './factories/unit/createUnitParser.js';
2
2
  const parseMilliseconds = createUnitParser({
3
3
  type: 'milliseconds',
4
4
  units: [
@@ -1,3 +1,3 @@
1
- import type { Parser } from './Parser';
1
+ import type { Parser } from './Parser.js';
2
2
  declare const parseNumber: Parser<number>;
3
3
  export { parseNumber, };
@@ -1,4 +1,4 @@
1
- import { ParseError } from './errors/ParseError';
1
+ import { ParseError } from './errors/ParseError.js';
2
2
  const parseNumber = (input) => {
3
3
  if ([undefined, null].includes(input)) {
4
4
  return 0;
@@ -1,3 +1,3 @@
1
- import type { Parser } from './Parser';
1
+ import type { Parser } from './Parser.js';
2
2
  declare const parseString: Parser<string>;
3
3
  export { parseString, };
@@ -1,4 +1,4 @@
1
- import { ParseError } from './errors/ParseError';
1
+ import { ParseError } from './errors/ParseError.js';
2
2
  const parseString = (input) => {
3
3
  if ([undefined, null].includes(input)) {
4
4
  return '';
@@ -1,5 +1,5 @@
1
1
  import bcrypt from 'bcryptjs';
2
- import { validateHashRounds } from './validateHashRounds';
2
+ import { validateHashRounds } from './validateHashRounds.js';
3
3
  class Pwd {
4
4
  hashRounds;
5
5
  constructor(params) {
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  declare class HashRoundsError extends BaseError {
3
3
  constructor(hashRounds: number);
4
4
  }
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  class HashRoundsError extends BaseError {
3
3
  constructor(hashRounds) {
4
4
  super(`invalid hash rounds "${hashRounds}"`);
@@ -1,4 +1,4 @@
1
- import { HashRoundsError } from './errors/HashRoundsError';
1
+ import { HashRoundsError } from './errors/HashRoundsError.js';
2
2
  const validateHashRounds = (hashRounds) => {
3
3
  if (hashRounds < 1) {
4
4
  throw new HashRoundsError(hashRounds);
@@ -1,6 +1,6 @@
1
- import type { Handler } from './Handler';
2
- import type { Method } from './Method';
3
- import type { Schema } from './Schema';
1
+ import type { Handler } from './Handler.js';
2
+ import type { Method } from './Method.js';
3
+ import type { Schema } from './Schema.js';
4
4
  interface Route {
5
5
  path: string;
6
6
  method: Method;
@@ -1,8 +1,8 @@
1
- import { OpenApiFormat } from './OpenApiFormat';
2
- import type { ErrorHandler } from './ErrorHandler';
3
- import type { Format } from './Format';
4
- import type { Handler } from './Handler';
5
- import type { Route } from './Route';
1
+ import { OpenApiFormat } from './OpenApiFormat.js';
2
+ import type { ErrorHandler } from './ErrorHandler.js';
3
+ import type { Format } from './Format.js';
4
+ import type { Handler } from './Handler.js';
5
+ import type { Route } from './Route.js';
6
6
  import type { OpenAPIV3 } from 'openapi-types';
7
7
  declare class Server {
8
8
  private readonly server;
@@ -3,8 +3,8 @@ import cors from '@fastify/cors';
3
3
  import responseValidation from '@fastify/response-validation';
4
4
  import swagger from '@fastify/swagger';
5
5
  import fastify from 'fastify';
6
- import { OpenApiFormat } from './OpenApiFormat';
7
- import { getAjv } from './getAjv';
6
+ import { OpenApiFormat } from './OpenApiFormat.js';
7
+ import { getAjv } from './getAjv.js';
8
8
  class Server {
9
9
  server;
10
10
  host;
@@ -1,4 +1,4 @@
1
1
  import { Ajv } from 'ajv';
2
- import type { Format } from './Format';
2
+ import type { Format } from './Format.js';
3
3
  declare const getAjv: (formats?: Format[]) => Ajv;
4
4
  export { getAjv, };
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  declare class FileReadError extends BaseError {
3
3
  constructor(path: string, message: string);
4
4
  }
@@ -1,4 +1,4 @@
1
- import { BaseError } from '../../error/BaseError';
1
+ import { BaseError } from '../../error/BaseError.js';
2
2
  class FileReadError extends BaseError {
3
3
  constructor(path, message) {
4
4
  super(`failed reading file "${path}": ${message}`);
@@ -1,4 +1,4 @@
1
- import type { Tls } from './Tls';
1
+ import type { Tls } from './Tls.js';
2
2
  declare const getTls: (tls?: Tls) => {
3
3
  key?: string;
4
4
  cert?: string;
@@ -1,4 +1,4 @@
1
- import { readFile } from './readFile';
1
+ import { readFile } from './readFile.js';
2
2
  const getTls = (tls) => {
3
3
  return tls
4
4
  ? {
@@ -1,5 +1,5 @@
1
1
  import fs from 'fs-extra';
2
- import { FileReadError } from './errors/FileReadError';
2
+ import { FileReadError } from './errors/FileReadError.js';
3
3
  const readFile = (path) => {
4
4
  try {
5
5
  if (fs.existsSync(path)) {