Skip to content

Commit 494e689

Browse files
bencooper222gregberge
authored andcommitted
feat: support single string entry (#43)
1 parent 71fdc0e commit 494e689

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/index.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,7 @@ class ErrorOverlayPlugin {
3737

3838
function adjustEntry(entry, enableDevServer, sockOptions) {
3939
if (typeof entry === 'string') {
40-
throw new Error(
41-
`We currently do not inject our entry code into single-file anonymous entries.
42-
Please use a multi-main (array) or object-form \`entry\` setting for now.`,
43-
)
40+
entry = [entry]; // for anonymous single entry points
4441
}
4542

4643
if (Array.isArray(entry)) {

0 commit comments

Comments
 (0)