Skip to content

Commit

Permalink
Use const enum
Browse files Browse the repository at this point in the history
  • Loading branch information
KSXGitHub committed Aug 11, 2019
1 parent 75268f3 commit 5519edb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/typescript/parse-dependency-range/lib/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export namespace Struct {
}
}

export enum Type {
export const enum Type {
Semver = 'semver',
Tarball = 'tarball',
Git = 'git',
Expand All @@ -71,14 +71,14 @@ export interface TarballUrl extends Url {
}

export namespace TarballUrl {
export enum Protocol {
export const enum Protocol {
FTP = 'ftp:',
FTPS = 'ftps:',
HTTP = 'http:',
HTTPS = 'https:'
}

export enum Extension {
export const enum Extension {
Tgz = '.tgz',
TarGz = '.tar.gz',
TarGzip = '.tar.gzip'
Expand All @@ -90,7 +90,7 @@ export interface GitUrl extends Url {
}

export namespace GitUrl {
export enum Protocol {
export const enum Protocol {
Git = 'git:',
SSH = 'git+ssh:',
HTTP = 'git+http:',
Expand All @@ -100,7 +100,7 @@ export namespace GitUrl {
}

export namespace LocalUrl {
export enum Protocol {
export const enum Protocol {
File = 'file:',
Link = 'link:'
}
Expand Down

0 comments on commit 5519edb

Please sign in to comment.