Create VERSIONING_STRATEGIES constant
Signed-off-by: Erik Engervall <erik.engervall@gmail.com>
This commit is contained in:
@@ -29,3 +29,11 @@ export const DISABLE_CACHE = {
|
||||
'If-None-Match': '',
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const VERSIONING_STRATEGIES: {
|
||||
semver: 'semver';
|
||||
calver: 'calver';
|
||||
} = {
|
||||
semver: 'semver',
|
||||
calver: 'calver',
|
||||
} as const;
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
import { createContext, useContext } from 'react';
|
||||
|
||||
import { VERSIONING_STRATEGIES } from '../constants/constants';
|
||||
import { GitHubReleaseManagerError } from '../errors/GitHubReleaseManagerError';
|
||||
|
||||
export interface Project {
|
||||
@@ -39,7 +40,7 @@ export interface Project {
|
||||
*
|
||||
* Default: false
|
||||
*/
|
||||
versioningStrategy: 'calver' | 'semver';
|
||||
versioningStrategy: keyof typeof VERSIONING_STRATEGIES;
|
||||
/**
|
||||
* Project props was provided via props
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user