diff options
author | Michael Trotter <spicydonuts@users.noreply.github.com> | 2018-06-14 03:31:34 -0600 |
---|---|---|
committer | eric <thul.eric@gmail.com> | 2018-06-14 05:31:34 -0400 |
commit | a2be98a0b804e82f23684f8fd3d8c24ad5ae3e40 (patch) | |
tree | fdde1f1645afeae58e41e15d06331cc575166bbf /src | |
parent | 2b017f9a225668f160ffca88b9b6efe01133a460 (diff) | |
download | purs-loader-a2be98a0b804e82f23684f8fd3d8c24ad5ae3e40.tar.gz purs-loader-a2be98a0b804e82f23684f8fd3d8c24ad5ae3e40.tar.zst purs-loader-a2be98a0b804e82f23684f8fd3d8c24ad5ae3e40.zip |
Update regex for 0.12.0 (#112)
Diffstat (limited to 'src')
-rw-r--r-- | src/to-javascript.js | 4 |
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. |
71 | function makeJS(psModule, psModuleMap, js) { | 71 | function 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 | ||