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

tslint-no-circular-imports

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tslint-no-circular-imports - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

7

noCircularImportsRule.js

@@ -39,3 +39,5 @@ "use strict";

// roots defined in tsconfig.json.
const resolvedImportFileName = path_1.resolve(path_1.dirname(thisFileName), importFileName + '.ts');
const resolvedImportFileName = isImportFromNPMPackage(importFileName)
? importFileName
: path_1.resolve(path_1.dirname(thisFileName), importFileName + '.ts');
// add to import graph

@@ -72,2 +74,5 @@ this.addToGraph(resolvedThisFileName, resolvedImportFileName);

}
function isImportFromNPMPackage(filename) {
return !(filename.startsWith('.') || filename.startsWith('/') || filename.startsWith('~'));
}
//# sourceMappingURL=noCircularImportsRule.js.map

10

noCircularImportsRule.ts

@@ -45,3 +45,5 @@ import { basename, resolve, dirname } from 'path'

// roots defined in tsconfig.json.
const resolvedImportFileName = resolve(dirname(thisFileName), importFileName + '.ts')
const resolvedImportFileName = isImportFromNPMPackage(importFileName)
? importFileName
: resolve(dirname(thisFileName), importFileName + '.ts')

@@ -86,2 +88,6 @@ // add to import graph

}
}
function isImportFromNPMPackage(filename: string) {
return !(filename.startsWith('.') || filename.startsWith('/') || filename.startsWith('~'))
}
{
"name": "tslint-no-circular-imports",
"version": "0.2.0",
"version": "0.2.1",
"description": "TSLint plugin to detect and warn about circular imports",

@@ -5,0 +5,0 @@ "main": "tslint-no-circular-imports.json",

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