Skip to content

Commit

Permalink
Fix attempt for issue keystonejs#3979
Browse files Browse the repository at this point in the history
packages.js generates a Uncaught SyntaxError: Unexpected string when minified, and fails to load the admin interface.
After some digging I found that uglifyjs compresses the typeof checks into the following format "undefined"==typeof x which triggers a syntax error after passing through another minification process when deployed.

A way to prevent this from happening is to allow semicolons in the uglifyjs command.
Also needed to add the 'aphrodite/no-important' to the required packages for the Admin UI.
  • Loading branch information
t100n committed Sep 8, 2017
1 parent 149fa4f commit 9d251d5
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 6,023 deletions.
1 change: 1 addition & 0 deletions admin/client/packages.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ module.exports = [
'moment',
'numeral',
'qs',
'aphrodite/no-important',
'react-addons-css-transition-group',
'react-alt-text',
'react-color',
Expand Down
Loading

0 comments on commit 9d251d5

Please sign in to comment.