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

@fimbul/ymir

Package Overview
Dependencies
Maintainers
2
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fimbul/ymir - npm Package Compare versions

Comparing version 0.6.0 to 0.8.0-dev.20180411

2

package.json
{
"name": "@fimbul/ymir",
"version": "0.6.0",
"version": "0.8.0-dev.20180411",
"description": "Core library for the Fimbullinter project",

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

@@ -77,2 +77,3 @@ import 'reflect-metadata';

export declare function excludeDeclarationFiles<T extends typeof AbstractRule>(target: T): void;
export declare function requireLibraryFile(fileName: string): <T extends typeof TypedRule>(target: T) => void;
export declare type RuleSupportsPredicate = (sourceFile: ts.SourceFile, context: RuleSupportsContext) => boolean;

@@ -79,0 +80,0 @@ export declare abstract class AbstractRule {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
require("reflect-metadata");
const ts = require("typescript");
const path = require("path");
class ConfigurationError extends Error {

@@ -59,2 +61,12 @@ }

exports.excludeDeclarationFiles = excludeDeclarationFiles;
function requireLibraryFile(fileName) {
return (target) => {
target.supports = combinePredicates(target.supports, (_, context) => programContainsLibraryFile(context.program, fileName));
};
}
exports.requireLibraryFile = requireLibraryFile;
function programContainsLibraryFile(program, fileName) {
const libFileDir = path.dirname(ts.getDefaultLibFilePath(program.getCompilerOptions()));
return program.getSourceFile(path.join(libFileDir, fileName)) !== undefined;
}
class AbstractRule {

@@ -61,0 +73,0 @@ constructor(context) {

Sorry, the diff of this file is not supported yet

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