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

@travetto/compiler

Package Overview
Dependencies
Maintainers
1
Versions
300
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@travetto/compiler - npm Package Compare versions

Comparing version 0.0.22 to 0.0.23

2

package.json

@@ -22,3 +22,3 @@ {

"scripts": {},
"version": "0.0.22"
"version": "0.0.23"
}

@@ -56,4 +56,2 @@ import * as ts from 'typescript';

}, exclude);
require.extensions['.ts'] = this.requireHandler.bind(this);
}

@@ -67,2 +65,5 @@

this.sourceManager.registerSourceMaps();
require.extensions['.ts'] = this.requireHandler.bind(this);
this.moduleManager.init();
const start = Date.now();

@@ -142,3 +143,3 @@ this.presenceManager.init();

if (this.presenceManager.isWatchedFileLoaded(fileName)) {
if (changed && this.presenceManager.isWatchedFileLoaded(fileName)) {
// If file is already loaded, mark for reload

@@ -160,2 +161,4 @@ this.markForReload(fileName);

export const Compiler = new $Compiler();
export const Compiler = new $Compiler();
export const Name = 20;
import { RetargettingHandler } from './proxy';
import { AppEnv } from '@travetto/base';
import { CompilerUtil } from './util';
import { Compiler } from '.';

@@ -13,3 +12,5 @@ const Module = require('module');

constructor(private cwd: string) {
constructor(private cwd: string) { }
init() {
Module._load = this.load.bind(this);

@@ -24,10 +25,7 @@ }

} catch (e) {
const p = Module._resolveFilename(request, parent);
if (!AppEnv.prod) { // If attempting to load an optional require
const p = Module._resolveFilename(request, parent);
console.error(`Unable to import ${p}, stubbing out`, e);
} else {
if (e) {
throw e;
}
} else if (e) {
throw e;
}

@@ -66,3 +64,3 @@

} catch (e) {
if (!AppEnv.prod) { // If attempting to load an optional require
if (AppEnv.watch) { // If attempting to load an optional require
console.error(`Unable to import ${name}, stubbing out`, e);

@@ -69,0 +67,0 @@ (m as any)._compile(CompilerUtil.EMPTY_MODULE, jsf);

@@ -23,2 +23,3 @@ import { Watcher, Entry, AppEnv, Handler, findAppFilesByExt } from '@travetto/base';

.filter(x => x.file.includes('/src/') && this.validFile(x.file))
.filter(x => !(x.file in require.cache)) // Pre-loaded items are fundamental and non-reloadable
.map(x => x.file);

@@ -58,3 +59,3 @@

} else {
this.buildWatcher(path.dirname(name), [{ testFile: x => x === path.basename(name) }]);
this.buildWatcher(`${this.cwd}/src`, [{ testFile: x => this.validFile(x) && x.endsWith('.ts') }]);
}

@@ -86,2 +87,3 @@ }

} else if (event === 'removed') {
this.files.delete(entry.file);
this.listener.removed(entry.file);

@@ -88,0 +90,0 @@ }

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