We're updating the issue view to help you get more done. 

require() does not handle JSON files, as other implementations do

Description

to reproduce:
1. add commonmark to project: npm install commonmark
2. require commonmark: commonmark = require('../node_modules/commonmark')
3. build: enyo pack
4. run

expected result: app loads normally

actual result: app fails to load with error:
SyntaxError: missing ; before statement
for the line where enyo pack has treated the required file as if it were executable JavaScript:
{{
,'.../node_modules/commonmark/node_modules/entities/maps/xml':[function (module,exports,global,require,request){
{"amp":"&","apos":"'","gt":">","lt":"<","quot":"\""}
}]
}}

Environment

OS X 10.11.6, Firefox

Status

Assignee

P. Douglas Reeder

Reporter

P. Douglas Reeder

Labels

None

External issue ID

None

Tango Test Run Elements

None

Old Issue Key

None

Components

Fix versions

Affects versions

2.7

Priority

None