[format] Run prettier

This commit is contained in:
Ferdinand Thiessen 2021-05-26 16:55:24 +02:00
parent 1f1d0fe32e
commit 6ab3bf2ad5
2 changed files with 13 additions and 11 deletions

2
types/index.d.ts vendored
View File

@ -1,3 +1,3 @@
/// <reference path="flaschengeist.d.ts" />
export * from "./plugin"
export * from './plugin';

22
types/plugin.d.ts vendored
View File

@ -2,16 +2,18 @@ import type { RouteLocationRaw, RouteRecordRaw, RouteRecordName } from 'vue-rout
import type { Component } from '@vue/runtime-core';
/* This is some sort of PEP440 subset */
type Join<T extends unknown[], D extends string> =
T extends [] ? '' :
T extends [string | number | boolean | bigint] ? `${T[0]}` :
T extends [string | number | boolean | bigint, ...infer U] ? `${T[0]}${D}${Join<U, D>}` :
string;
type BaseVersion = Join<[number, number], '.'> | Join<[number, number, number], '.'>
type PreRelease = Join<[["a"|"b"|"rc"], number], ".">
type PRVersion = BaseVersion | `${BaseVersion}${PreRelease}`
type Join<T extends unknown[], D extends string> = T extends []
? ''
: T extends [string | number | boolean | bigint]
? `${T[0]}`
: T extends [string | number | boolean | bigint, ...infer U]
? `${T[0]}${D}${Join<U, D>}`
: string;
type BaseVersion = Join<[number, number], '.'> | Join<[number, number, number], '.'>;
type PreRelease = Join<[['a' | 'b' | 'rc'], number], '.'>;
type PRVersion = BaseVersion | `${BaseVersion}${PreRelease}`;
/** A PEP440 subset used to describe backend module versions */
export type PEP440Version = PRVersion | `${PRVersion}.dev${number}`
export type PEP440Version = PRVersion | `${PRVersion}.dev${number}`;
export namespace FG_Plugin {
/**
@ -19,7 +21,7 @@ export namespace FG_Plugin {
*/
export interface Plugin {
/** Unique identifier for this plugin, we recommend using a FQN like com.example.my_plugin */
id: string,
id: string;
/** Arbitrary name of the plugin used inside admin view etc */
name: string;
/** Version of this plugin, used for dependencies. MUST be semver parsable */