![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@depanlz/core
Advanced tools
这个模块在项目依赖分析中扮演着核心角色,集成了关键的依赖分析功能,将各种依赖分析的任务统一在一个模块中。
declare class DepAnlz {
depth: number;
constructor(depth: number);
preHook(): Config;
coreHook(config: Config): DepGraph;
postHook(callback: (config:Config, depGraph: DepGraph) => any): any;
lifeCycle(): DepGraph;
}
DepAnlz
类是我们分析项目依赖的核心,我们可以通过DepAnlz
实例对象身上的一些Hook
方法,来定制化个人的依赖分析行为。
$ npm install @depanlz/core
$ pnpm add @depanlz/core
$ yarn add @depanlz/core
有关 typescript
的类型声明
type Config = {
PKG_JSON_DIR: string,
NODE_MODULES_DIR: string,
PKG_MANAGER: string,
DEPTH: number
}
type DepNode = {
id: string,
dependence: string,
version: string,
level: number
}
type DepRel = {
source: string,
target: string
}
declare class DepGraph {
nodes: Array<DepNode>;
edges: Array<DepRel>;
constructor();
insertEgde(fromNodeId: string, toNodeId: string): void;
insertNode(dependence: string, version: string, level: number):void ;
}
使用 DepAnlz
类构建实例,以及进行依赖分析,加工处理等。
import { DepAnlz, Config, DepGraph } from "@depanlz/core"
const depth: number = 3
const anlz: DepAnlz = new DepAnlz(depth)
const config: Config = anlz.preHook()
const depGraph: DepGraph = anlz.coreHook(config)
function callback (config: Config, depGraph: DepGraph): void {
console.log(config)
console.log(depGraph)
}
anlz.postHook(callback)
FAQs
We found that @depanlz/core demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.