New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@koishijs/loader

Package Overview
Dependencies
Maintainers
1
Versions
114
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@koishijs/loader - npm Package Compare versions

Comparing version 2.6.0 to 2.6.1

lib/index.js

70

lib/index.d.ts

@@ -1,52 +0,22 @@

import { Context, Dict, EnvData } from '@koishijs/core';
declare module '@koishijs/core' {
interface Context {
loader: Loader;
}
interface Events {
'config'(): void;
}
namespace Context {
interface Config {
name?: string;
plugins?: Dict;
}
}
}
declare module 'cordis' {
interface EffectScope<C> {
[Loader.kRecord]?: Dict<ForkScope<C>>;
alias?: string;
}
}
export declare function unwrapExports(module: any): any;
export interface Modifier {
$if?: boolean;
$filter?: Selection;
}
export declare abstract class Loader {
static readonly kRecord: unique symbol;
static readonly exitCode = 51;
envData: EnvData;
ctxData: {};
app: Context;
/// <reference types="node" />
import { Context } from '@koishijs/core';
import { Loader } from './shared';
import ns from 'ns-require';
export * from './shared';
export default class NodeLoader extends Loader {
envData: any;
baseDir: string;
config: Context.Config;
entry: Context;
suspend: boolean;
filename: string;
writable: boolean;
envfile: string;
cache: Dict<string>;
abstract readConfig(): Context.Config;
abstract writeConfig(): void;
abstract resolve(name: string): Promise<string>;
abstract resolvePlugin(name: string): Promise<any>;
abstract fullReload(): void;
interpolate(source: any): any;
private forkPlugin;
isTruthyLike(expr: any): boolean;
reloadPlugin(parent: Context, key: string, source: any): Promise<import("cordis").ForkScope<Context>>;
unloadPlugin(ctx: Context, key: string): void;
createApp(): Promise<Context>;
extname: string;
scope: ns.Scope;
ctxData: {
env: NodeJS.ProcessEnv;
};
constructor(filename?: string);
private checkWritable;
private findConfig;
readConfig(): Context.Config;
writeConfig(): void;
resolve(name: string): Promise<string>;
resolvePlugin(name: string): Promise<any>;
fullReload(code?: number): void;
}
{
"name": "@koishijs/loader",
"description": "Config Loader for Koishi",
"version": "2.6.0",
"main": "lib/node.js",
"module": "lib/index.mjs",
"typings": "lib/node.d.ts",
"version": "2.6.1",
"main": "lib/index.js",
"module": "lib/shared.mjs",
"typings": "lib/index.d.ts",
"files": [

@@ -9,0 +9,0 @@ "lib"

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