From e705e3e045b6975733bc581ae6f2e7db3065bf0a Mon Sep 17 00:00:00 2001 From: Kevin Sawicki & Nathan Sobo Date: Mon, 22 Jul 2013 11:44:39 -0700 Subject: [PATCH] Don't allow caching of coffee requires to be overridden Previously coffeestack was requiring a different version of coffeescript than atom was, which had a side effect of re-registering the extension handler for .coffee requires. This disabled coffee-cache, which made require really slow again. --- static/index.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/static/index.html b/static/index.html index b3e3b809d..abbfbb7bf 100644 --- a/static/index.html +++ b/static/index.html @@ -9,6 +9,10 @@ try { require('coffee-script'); require('coffee-cache').setCacheDir('/tmp/atom-coffee-cache'); + Object.defineProperty(require.extensions, '.coffee', { + writable: false, + value: require.extensions['.coffee'] + }); require(currentWindow.loadSettings.bootstrapScript); currentWindow.emit('window:loaded'); }