Skip to content

Commit

Permalink
Merge pull request #86 from platformatic/renovate/platformatic
Browse files Browse the repository at this point in the history
Update platformatic to ^0.45.0
  • Loading branch information
MzUgM authored Sep 22, 2023
2 parents 64a3bbe + 06ce563 commit f5fbb1c
Show file tree
Hide file tree
Showing 10 changed files with 2,104 additions and 1,439 deletions.
35 changes: 24 additions & 11 deletions global.d.ts
Original file line number Diff line number Diff line change
@@ -1,26 +1,39 @@
import { Entity } from '@platformatic/sql-mapper';
import graphqlPlugin from '@platformatic/sql-graphql'
import { Queue } from './types/Queue'
import { Message } from './types/Message'
import { Cron } from './types/Cron'
import type { PlatformaticApp, PlatformaticDBMixin, PlatformaticDBConfig, Entity, Entities, EntityHooks } from '@platformatic/db'
import { EntityTypes, Cron,Message,Page,Queue } from './types'

declare module 'fastify' {
interface FastifyInstance {
getSchema(schemaId: 'Queue' | 'Message' | 'Cron'): {
getSchema<T extends 'Cron' | 'Message' | 'Page' | 'Queue'>(schemaId: T): {
'$id': string,
title: string,
description: string,
type: string,
properties: object,
properties: {
[x in keyof EntityTypes[T]]: { type: string, nullable?: boolean }
},
required: string[]
};
}
}

declare module '@platformatic/sql-mapper' {
interface Entities {
queue: Entity<Queue>,
interface AppEntities extends Entities {
cron: Entity<Cron>,
message: Entity<Message>,
cron: Entity<Cron>,
page: Entity<Page>,
queue: Entity<Queue>,
}

interface AppEntityHooks {
addEntityHooks(entityName: 'cron', hooks: EntityHooks<Cron>): any
addEntityHooks(entityName: 'message', hooks: EntityHooks<Message>): any
addEntityHooks(entityName: 'page', hooks: EntityHooks<Page>): any
addEntityHooks(entityName: 'queue', hooks: EntityHooks<Queue>): any
}

declare module 'fastify' {
interface FastifyInstance {
platformatic: PlatformaticApp<PlatformaticDBConfig> &
PlatformaticDBMixin<AppEntities> &
AppEntityHooks
}
}
2,812 changes: 2,038 additions & 774 deletions package-lock.json

Large diffs are not rendered by default.

7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,13 @@
"tap": "^16.3.2"
},
"dependencies": {
"@platformatic/sql-graphql": "^0.40.0",
"@platformatic/sql-mapper": "^0.40.0",
"@platformatic/db": "^0.45.0",
"c8": "^8.0.0",
"cron-parser": "^4.7.1",
"fastify-plugin": "^4.5.0",
"platformatic": "^0.40.0"
"platformatic": "^0.45.0"
},
"engines": {
"node": "^16.17.0 || ^18.8.0 || >=19"
"node": "^18.8.0 || >=19"
}
}
2 changes: 1 addition & 1 deletion platformatic.db.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"$schema": "https://platformatic.dev/schemas/v0.19.0/db",
"$schema": "https://platformatic.dev/schemas/v0.45.0/db",
"server": {
"hostname": "{PLT_SERVER_HOSTNAME}",
"port": "{PORT}",
Expand Down
Loading

0 comments on commit f5fbb1c

Please sign in to comment.