diff --git a/dist/index.js b/dist/index.js index 28b630d..f505b2b 100755 --- a/dist/index.js +++ b/dist/index.js @@ -60,7 +60,7 @@ var EXPORT_COMMENT = `/** * This file was @generated using pocketbase-typegen */`; var IMPORTS = `import type PocketBase from 'pocketbase' -import { type RecordService } from 'pocketbase'`; +import type { RecordService } from 'pocketbase'`; var RECORD_TYPE_COMMENT = `// Record types for each collection`; var RESPONSE_TYPE_COMMENT = `// Response types include system fields and match responses from the PocketBase API`; var ALL_RECORD_RESPONSE_COMMENT = `// Types containing all Records and Responses, useful for creating typing helper functions`; @@ -319,7 +319,7 @@ async function main(options2) { import { program } from "commander"; // package.json -var version = "1.2.0"; +var version = "1.2.1"; // src/index.ts program.name("Pocketbase Typegen").version(version).description( diff --git a/package.json b/package.json index 7f1fc10..54d64f6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "pocketbase-typegen", - "version": "1.2.0", + "version": "1.2.1", "description": "Generate pocketbase record types from your database", "main": "dist/index.js", "bin": { diff --git a/src/constants.ts b/src/constants.ts index ce951d5..96af33e 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -2,7 +2,7 @@ export const EXPORT_COMMENT = `/** * This file was @generated using pocketbase-typegen */` export const IMPORTS = `import type PocketBase from 'pocketbase' -import { type RecordService } from 'pocketbase'` +import type { RecordService } from 'pocketbase'` export const RECORD_TYPE_COMMENT = `// Record types for each collection` export const RESPONSE_TYPE_COMMENT = `// Response types include system fields and match responses from the PocketBase API` export const ALL_RECORD_RESPONSE_COMMENT = `// Types containing all Records and Responses, useful for creating typing helper functions` diff --git a/test/__snapshots__/fromJSON.test.ts.snap b/test/__snapshots__/fromJSON.test.ts.snap index 12f8f13..e787f61 100644 --- a/test/__snapshots__/fromJSON.test.ts.snap +++ b/test/__snapshots__/fromJSON.test.ts.snap @@ -6,7 +6,7 @@ exports[`creates a type file from json schema 1`] = ` */ import type PocketBase from 'pocketbase' -import { type RecordService } from 'pocketbase' +import type { RecordService } from 'pocketbase' export enum Collections { Base = "base", diff --git a/test/__snapshots__/lib.test.ts.snap b/test/__snapshots__/lib.test.ts.snap index 845b041..ee6c8fe 100644 --- a/test/__snapshots__/lib.test.ts.snap +++ b/test/__snapshots__/lib.test.ts.snap @@ -26,7 +26,7 @@ exports[`generate generates correct output given db input 1`] = ` */ import type PocketBase from 'pocketbase' -import { type RecordService } from 'pocketbase' +import type { RecordService } from 'pocketbase' export enum Collections { Books = "books", diff --git a/test/pocketbase-types-example.ts b/test/pocketbase-types-example.ts index b736bf9..e1d7d3e 100644 --- a/test/pocketbase-types-example.ts +++ b/test/pocketbase-types-example.ts @@ -3,7 +3,7 @@ */ import type PocketBase from 'pocketbase' -import { type RecordService } from 'pocketbase' +import type { RecordService } from 'pocketbase' export enum Collections { Base = "base",