aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/to-javascript.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/to-javascript.js')
-rw-r--r--src/to-javascript.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/to-javascript.js b/src/to-javascript.js
index 28dde7a..a7d64a2 100644
--- a/src/to-javascript.js
+++ b/src/to-javascript.js
@@ -69,9 +69,9 @@ function makeBundleJS(psModule) {
69// any new imports in order to allow webpack to watch the new files 69// any new imports in order to allow webpack to watch the new files
70// before they have been successfully compiled. 70// before they have been successfully compiled.
71function makeJS(psModule, psModuleMap, js) { 71function makeJS(psModule, psModuleMap, js) {
72 const requireRE = /require\(['"]\.\.\/([\w\.]+)['"]\)/g; 72 const requireRE = /require\(['"]\.\.\/([\w\.]+)(?:\/index\.js)?['"]\)/g;
73 73
74 const foreignRE = /require\(['"]\.\/foreign['"]\)/g; 74 const foreignRE = /require\(['"]\.\/foreign(?:\.js)?['"]\)/g;
75 75
76 const name = psModule.name; 76 const name = psModule.name;
77 77