mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 13:59:16 +01:00
chore: ⬆️ Upgrade to Biome 2.0
This commit is contained in:
parent
e7aec8752c
commit
963173cdae
174 changed files with 412 additions and 379 deletions
|
|
@ -1,3 +1,2 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { type Output, ResponseError } from "./versia/base.ts";
|
||||
export { Client } from "./versia/client.ts";
|
||||
|
|
|
|||
|
|
@ -32,7 +32,9 @@
|
|||
}
|
||||
],
|
||||
"description": "Client for Mastodon and Versia API",
|
||||
"categories": ["Other"],
|
||||
"categories": [
|
||||
"Other"
|
||||
],
|
||||
"type": "module",
|
||||
"engines": {
|
||||
"bun": ">=1.2.5"
|
||||
|
|
@ -52,7 +54,13 @@
|
|||
"url": "https://opencollective.com/lysand"
|
||||
},
|
||||
"homepage": "https://versia.pub",
|
||||
"keywords": ["versia", "mastodon", "api", "typescript", "rest"],
|
||||
"keywords": [
|
||||
"versia",
|
||||
"mastodon",
|
||||
"api",
|
||||
"typescript",
|
||||
"rest"
|
||||
],
|
||||
"packageManager": "bun@1.2.5",
|
||||
"dependencies": {
|
||||
"@badgateway/oauth2-client": "^2.4.2"
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { Account, Field, Source } from "./schemas/account.ts";
|
||||
export { AccountWarning } from "./schemas/account-warning.ts";
|
||||
export { Account, Source, Field } from "./schemas/account.ts";
|
||||
export { Appeal } from "./schemas/appeal.ts";
|
||||
export { Application, CredentialApplication } from "./schemas/application.ts";
|
||||
export { Attachment } from "./schemas/attachment.ts";
|
||||
export { PreviewCard, PreviewCardAuthor } from "./schemas/card.ts";
|
||||
export { Id, iso631, zBoolean } from "./schemas/common.ts";
|
||||
export { Context } from "./schemas/context.ts";
|
||||
export { CustomEmoji } from "./schemas/emoji.ts";
|
||||
export { ExtendedDescription } from "./schemas/extended-description.ts";
|
||||
|
|
@ -15,10 +15,11 @@ export {
|
|||
FilterResult,
|
||||
FilterStatus,
|
||||
} from "./schemas/filters.ts";
|
||||
export { InstanceV1 } from "./schemas/instance-v1.ts";
|
||||
export { Instance } from "./schemas/instance.ts";
|
||||
export { InstanceV1 } from "./schemas/instance-v1.ts";
|
||||
export { Marker } from "./schemas/marker.ts";
|
||||
export { Notification } from "./schemas/notification.ts";
|
||||
export { RolePermission } from "./schemas/permissions.ts";
|
||||
export { Poll, PollOption } from "./schemas/poll.ts";
|
||||
export { Preferences } from "./schemas/preferences.ts";
|
||||
export { PrivacyPolicy } from "./schemas/privacy-policy.ts";
|
||||
|
|
@ -30,15 +31,13 @@ export { Relationship } from "./schemas/relationship.ts";
|
|||
export { Report } from "./schemas/report.ts";
|
||||
export { Rule } from "./schemas/rule.ts";
|
||||
export { Search } from "./schemas/search.ts";
|
||||
export { Status, Mention, StatusSource } from "./schemas/status.ts";
|
||||
export { Mention, Status, StatusSource } from "./schemas/status.ts";
|
||||
export { Tag } from "./schemas/tag.ts";
|
||||
export { Token } from "./schemas/token.ts";
|
||||
export { TermsOfService } from "./schemas/tos.ts";
|
||||
export {
|
||||
Role,
|
||||
NoteReaction,
|
||||
SSOConfig,
|
||||
Challenge,
|
||||
NoteReaction,
|
||||
Role,
|
||||
SSOConfig,
|
||||
} from "./schemas/versia.ts";
|
||||
export { RolePermission } from "./schemas/permissions.ts";
|
||||
export { Id, iso631, zBoolean } from "./schemas/common.ts";
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { userAddressValidator } from "@/api.ts";
|
||||
import { z } from "zod";
|
||||
import { userAddressValidator } from "@/api.ts";
|
||||
import { config } from "~/config.ts";
|
||||
import { iso631, zBoolean } from "./common.ts";
|
||||
import { CustomEmoji } from "./emoji.ts";
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { emojiValidator } from "@/api.ts";
|
||||
import { z } from "zod";
|
||||
import { emojiValidator } from "@/api.ts";
|
||||
import { config } from "~/config.ts";
|
||||
import { Id, zBoolean } from "./common.ts";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { z } from "zod";
|
||||
import { AccountWarning } from "./account-warning.ts";
|
||||
import { Account } from "./account.ts";
|
||||
import { AccountWarning } from "./account-warning.ts";
|
||||
import { Id } from "./common.ts";
|
||||
import { Report } from "./report.ts";
|
||||
import { Status } from "./status.ts";
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
// biome-ignore lint/correctness/noUndeclaredDependencies: biome is looking at the wrong package.json
|
||||
import { OAuth2Client } from "@badgateway/oauth2-client";
|
||||
import type { z } from "zod";
|
||||
import type { Account } from "../schemas/account.ts";
|
||||
|
|
|
|||
|
|
@ -1,16 +1,15 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { User } from "~/classes/database/user.ts";
|
||||
export { Role } from "~/classes/database/role.ts";
|
||||
export { Media } from "~/classes/database/media";
|
||||
export { Application } from "~/classes/database/application.ts";
|
||||
export { Emoji } from "~/classes/database/emoji.ts";
|
||||
export { Instance } from "~/classes/database/instance.ts";
|
||||
export { Note } from "~/classes/database/note.ts";
|
||||
export { Timeline } from "~/classes/database/timeline.ts";
|
||||
export { Application } from "~/classes/database/application.ts";
|
||||
export { db } from "~/drizzle/db.ts";
|
||||
export { Relationship } from "~/classes/database/relationship.ts";
|
||||
export { Like } from "~/classes/database/like.ts";
|
||||
export { Token } from "~/classes/database/token.ts";
|
||||
export { Media } from "~/classes/database/media";
|
||||
export { Note } from "~/classes/database/note.ts";
|
||||
export { Notification } from "~/classes/database/notification.ts";
|
||||
export { Reaction } from "~/classes/database/reaction.ts";
|
||||
export { PushSubscription } from "~/classes/database/pushsubscription.ts";
|
||||
export { Reaction } from "~/classes/database/reaction.ts";
|
||||
export { Relationship } from "~/classes/database/relationship.ts";
|
||||
export { Role } from "~/classes/database/role.ts";
|
||||
export { Timeline } from "~/classes/database/timeline.ts";
|
||||
export { Token } from "~/classes/database/token.ts";
|
||||
export { User } from "~/classes/database/user.ts";
|
||||
export { db } from "~/drizzle/db.ts";
|
||||
|
|
|
|||
|
|
@ -1,3 +1 @@
|
|||
// biome-ignore lint/performance/noReExportAll: <explanation>
|
||||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export * from "drizzle-orm";
|
||||
|
|
|
|||
|
|
@ -1,3 +1 @@
|
|||
// biome-ignore lint/performance/noReExportAll: <explanation>
|
||||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export * from "~/drizzle/schema";
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { Hooks } from "./hooks.ts";
|
||||
export { Plugin } from "./plugin.ts";
|
||||
export type { Manifest } from "./schema.ts";
|
||||
|
|
|
|||
|
|
@ -14,7 +14,11 @@
|
|||
},
|
||||
"icon": "https://github.com/versia-pub/server",
|
||||
"license": "AGPL-3.0-or-later",
|
||||
"keywords": ["federated", "activitypub", "bun"],
|
||||
"keywords": [
|
||||
"federated",
|
||||
"activitypub",
|
||||
"bun"
|
||||
],
|
||||
"maintainers": [
|
||||
{
|
||||
"email": "contact@cpluspatch.com",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import type { Hono, MiddlewareHandler } from "hono";
|
||||
import { createMiddleware } from "hono/factory";
|
||||
import type { z } from "zod";
|
||||
import { type ZodError, fromZodError } from "zod-validation-error";
|
||||
import { fromZodError, type ZodError } from "zod-validation-error";
|
||||
import type { HonoEnv } from "~/types/api";
|
||||
import type { ServerHooks } from "./hooks.ts";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,21 +1,20 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { User } from "./user.ts";
|
||||
export { Note } from "./note.ts";
|
||||
export { Entity } from "./entity.ts";
|
||||
export { Delete } from "./delete.ts";
|
||||
export { InstanceMetadata } from "./instancemetadata.ts";
|
||||
export { Collection, URICollection } from "./collection.ts";
|
||||
export {
|
||||
ImageContentFormat,
|
||||
AudioContentFormat,
|
||||
ContentFormat,
|
||||
ImageContentFormat,
|
||||
NonTextContentFormat,
|
||||
TextContentFormat,
|
||||
ContentFormat,
|
||||
VideoContentFormat,
|
||||
} from "./contentformat.ts";
|
||||
export { Follow, FollowAccept, FollowReject, Unfollow } from "./follow.ts";
|
||||
export { Collection, URICollection } from "./collection.ts";
|
||||
export { Like, Dislike } from "./extensions/likes.ts";
|
||||
export { Delete } from "./delete.ts";
|
||||
export { Entity } from "./entity.ts";
|
||||
export { Dislike, Like } from "./extensions/likes.ts";
|
||||
export { Vote } from "./extensions/polls.ts";
|
||||
export { Reaction } from "./extensions/reactions.ts";
|
||||
export { Report } from "./extensions/reports.ts";
|
||||
export { Share } from "./extensions/share.ts";
|
||||
export { Follow, FollowAccept, FollowReject, Unfollow } from "./follow.ts";
|
||||
export { InstanceMetadata } from "./instancemetadata.ts";
|
||||
export { Note } from "./note.ts";
|
||||
export { User } from "./user.ts";
|
||||
|
|
|
|||
|
|
@ -32,7 +32,9 @@
|
|||
}
|
||||
],
|
||||
"description": "Versia Federation SDK",
|
||||
"categories": ["Other"],
|
||||
"categories": [
|
||||
"Other"
|
||||
],
|
||||
"type": "module",
|
||||
"engines": {
|
||||
"bun": ">=1.2.5"
|
||||
|
|
@ -64,6 +66,10 @@
|
|||
"url": "https://opencollective.com/lysand"
|
||||
},
|
||||
"homepage": "https://versia.pub",
|
||||
"keywords": ["versia", "typescript", "sdk"],
|
||||
"keywords": [
|
||||
"versia",
|
||||
"typescript",
|
||||
"sdk"
|
||||
],
|
||||
"packageManager": "bun@1.2.5"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { z } from "zod";
|
||||
import { url, u64 } from "./common.ts";
|
||||
import { u64, url } from "./common.ts";
|
||||
|
||||
export const CollectionSchema = z.strictObject({
|
||||
author: url.nullable(),
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { z } from "zod";
|
||||
import { isISOString } from "../../regex.ts";
|
||||
import { url, u64 } from "../common.ts";
|
||||
import { u64, url } from "../common.ts";
|
||||
import { TextContentFormatSchema } from "../contentformat.ts";
|
||||
import { EntitySchema } from "../entity.ts";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,27 +1,26 @@
|
|||
// biome-ignore lint/performance/noBarrelFile: <explanation>
|
||||
export { UserSchema } from "./user.ts";
|
||||
export { NoteSchema } from "./note.ts";
|
||||
export { EntitySchema } from "./entity.ts";
|
||||
export { DeleteSchema } from "./delete.ts";
|
||||
export { InstanceMetadataSchema } from "./instance.ts";
|
||||
export { CollectionSchema, URICollectionSchema } from "./collection.ts";
|
||||
export {
|
||||
AudioContentFormatSchema,
|
||||
ContentFormatSchema,
|
||||
ImageContentFormatSchema,
|
||||
AudioContentFormatSchema,
|
||||
NonTextContentFormatSchema,
|
||||
TextContentFormatSchema,
|
||||
VideoContentFormatSchema,
|
||||
} from "./contentformat.ts";
|
||||
export {
|
||||
FollowSchema,
|
||||
FollowAcceptSchema,
|
||||
FollowRejectSchema,
|
||||
UnfollowSchema,
|
||||
} from "./follow.ts";
|
||||
export { CollectionSchema, URICollectionSchema } from "./collection.ts";
|
||||
export { LikeSchema, DislikeSchema } from "./extensions/likes.ts";
|
||||
export { DeleteSchema } from "./delete.ts";
|
||||
export { EntitySchema } from "./entity.ts";
|
||||
export { DislikeSchema, LikeSchema } from "./extensions/likes.ts";
|
||||
export { VoteSchema } from "./extensions/polls.ts";
|
||||
export { ReactionSchema } from "./extensions/reactions.ts";
|
||||
export { ReportSchema } from "./extensions/reports.ts";
|
||||
export { ShareSchema } from "./extensions/share.ts";
|
||||
export {
|
||||
FollowAcceptSchema,
|
||||
FollowRejectSchema,
|
||||
FollowSchema,
|
||||
UnfollowSchema,
|
||||
} from "./follow.ts";
|
||||
export { InstanceMetadataSchema } from "./instance.ts";
|
||||
export { NoteSchema } from "./note.ts";
|
||||
export { UserSchema } from "./user.ts";
|
||||
export { WebFingerSchema } from "./webfinger.ts";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue