Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@kubb/core

Package Overview
Dependencies
Maintainers
1
Versions
676
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kubb/core - npm Package Compare versions

Comparing version 0.52.0 to 0.53.0

19

dist/index.d.ts

@@ -108,9 +108,10 @@ import EventEmitter from 'eventemitter3';

options?: TOptions['options'];
} & Partial<PluginLifecycle>;
type PluginFactoryOptions<Options = unknown, Nested extends boolean = false, Api = any> = {
} & Partial<PluginLifecycle<TOptions>>;
type PluginFactoryOptions<Options = unknown, Nested extends boolean = false, Api = any, ResolveIdOptions = Record<string, any>> = {
options: Options;
resolveIdOptions: ResolveIdOptions;
nested: Nested;
api: Api;
};
type PluginLifecycle = {
type PluginLifecycle<TOptions extends PluginFactoryOptions = PluginFactoryOptions> = {
/**

@@ -131,3 +132,3 @@ * Valdiate all plugins to see if their depended plugins are installed and configured.

*/
resolveId: (this: PluginContext, fileName: string, directory?: string, options?: Record<string, any>) => OptionalPath;
resolveId: (this: PluginContext, fileName: string, directory?: string, options?: TOptions['resolveIdOptions']) => OptionalPath;
/**

@@ -155,3 +156,3 @@ * Makes it possible to run async logic to override the path defined previously by `resolveId`.

type PluginLifecycleHooks = keyof PluginLifecycle;
type ResolveIdParams = {
type ResolveIdParams<TOptions = Record<string, any>> = {
fileName: string;

@@ -167,5 +168,5 @@ directory?: string | undefined;

*/
options?: Record<string, any>;
options?: TOptions;
};
type PluginContext = {
type PluginContext<TOptions = Record<string, any>> = {
config: KubbConfig;

@@ -175,3 +176,3 @@ cache: Cache;

addFile: (file: File) => Promise<File>;
resolveId: (params: ResolveIdParams) => MaybePromise<OptionalPath>;
resolveId: (params: ResolveIdParams<TOptions>) => MaybePromise<OptionalPath>;
load: (id: string) => MaybePromise<TransformResult | void>;

@@ -343,3 +344,3 @@ };

declare const hooks: [keyof PluginLifecycle];
declare const hooks: [keyof PluginLifecycle<PluginFactoryOptions<unknown, false, any, Record<string, any>>>];
declare class PluginManager {

@@ -346,0 +347,0 @@ plugins: KubbPlugin[];

{
"name": "@kubb/core",
"version": "0.52.0",
"version": "0.53.0",
"description": "Generator core",

@@ -5,0 +5,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc