aboutsummaryrefslogtreecommitdiffstats
path: root/packages/json-schemas/schemas/basic_type_schemas.ts
blob: 2cf32b384735a5574370335813e1676e37f563b9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
export const addressSchema = {
    id: '/Address',
    type: 'string',
    pattern: '^0x[0-9a-f]{40}$',
};

export const hexSchema = {
    id: '/Hex',
    type: 'string',
    pattern: '^0x([0-9a-f][0-9a-f])*$',
};

export const numberSchema = {
    id: '/Number',
    type: 'string',
    pattern: '^\\d+(\\.\\d+)?$',
};