Skip to content
Browse files

fix require() as per @defunctzombie's suggestion

  • Loading branch information...
1 parent 572c195 commit 2962f7e87f9e9b167705bdef537348c594fdbc06 @jonathanong jonathanong committed Mar 6, 2014
Showing with 9 additions and 1 deletion.
  1. +6 −1 index.js
  2. +3 −0 package.json
View
7 index.js
@@ -2,7 +2,12 @@
* Module dependencies.
*/
-var type = require('component-type');
+var type;
+try {
+ type = require('component-type');
+} catch (_) {
+ type = require('type');
+}
/**
* Module exports.
View
3 package.json
@@ -19,5 +19,8 @@
"repository": {
"type": "git",
"url": "https://github.com/component/clone.git"
+ },
+ "browser": {
+ "type": "component-type"
}
}

0 comments on commit 2962f7e

Please sign in to comment.
Something went wrong with that request. Please try again.