Skip to content

Commit

Permalink
Linting
Browse files Browse the repository at this point in the history
  • Loading branch information
mikek-mnx committed May 9, 2024
1 parent 84a669a commit c01872e
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions src/string-decimal.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
import type * as z from "zod";
import { Numeric } from "./numeric.js";
import type {} from "bigdecimal";
import type * as z from 'zod';
import { Numeric } from './numeric.js';
import type {} from 'bigdecimal';

export type StringDecimal = z.infer<typeof StringDecimal>;
export const StringDecimal = Numeric.transform((v) => v.toString()).brand(
"StringDecimal",
);
export const StringDecimal = Numeric.transform((v) => v.toString()).brand('StringDecimal');

export type PositiveStringDecimal = z.infer<typeof PositiveStringDecimal>;
export const PositiveStringDecimal = Numeric.refine(
(v) => v.gte(0),
"invalid_positive_decimal_string",
)
export const PositiveStringDecimal = Numeric.refine((v) => v.gte(0), 'invalid_positive_decimal_string')
.transform((v) => v.toString())
.brand("PositiveStringDecimal");
.brand('PositiveStringDecimal');

0 comments on commit c01872e

Please sign in to comment.