@pogodisco/response 0.0.1 → 0.0.2

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.
package/dist/index.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from "./types/response";
2
- export * from "./utils/response";
1
+ export * from "./types/response.js";
2
+ export * from "./utils/response.js";
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- export * from "./types/response";
2
- export * from "./utils/response";
1
+ export * from "./types/response.js";
2
+ export * from "./utils/response.js";
@@ -1,4 +1,4 @@
1
- import { type BaseResponse, type FailureResponse, type SuccessResponse, TResponse } from "../types/response";
1
+ import { type BaseResponse, type FailureResponse, type SuccessResponse, TResponse } from "../types/response.js";
2
2
  export declare function newSuccessResponse<T>(data: T, opts?: Partial<Pick<BaseResponse, "message" | "status">>): SuccessResponse<T>;
3
3
  export declare function newFailureResponse(error: string, opts?: Partial<Pick<FailureResponse, "message" | "status" | "level" | "errors">>): FailureResponse;
4
4
  export declare function isFailure<T>(resp: TResponse<T>): resp is FailureResponse;
@@ -1,4 +1,4 @@
1
- import { ResponseLevel, } from "../types/response";
1
+ import { ResponseLevel, } from "../types/response.js";
2
2
  export function newSuccessResponse(data, opts) {
3
3
  const { message = "", status = 200 } = opts ?? {};
4
4
  return { ok: true, data, message, status, level: ResponseLevel.SUCCESS };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pogodisco/response",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },