Skip to content

Commit 641664b

Browse files
committed
Fix: AppChunk broken by the new package packing approach
1 parent c0ac101 commit 641664b

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

config/webpack/app-base.js

+3
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ module.exports = function configFactory(ops) {
6767
/* A random 32-bit key, that can be used for encryption. */
6868
key: forge.random.getBytesSync(32),
6969

70+
/* Public path used during build. */
71+
publicPath: o.publicPath,
72+
7073
/* Build timestamp. */
7174
timestamp: now.utc().toISOString(),
7275
};

package-lock.json

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,5 +121,5 @@
121121
"mkDistDir:prod": "mkdir -p dist/prod/shared/utils && mkdir -p dist/prod/client",
122122
"test": "npm run lint && npm run jest"
123123
},
124-
"version": "0.6.5"
124+
"version": "0.6.6"
125125
}

src/shared/containers/AppChunk/index.jsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* https://github.com/topcoder-platform/community-app/blob/develop/docs/code-splitting.md
77
*/
88

9-
/* global document, PUBLIC_PATH, window */
9+
/* global document, window */
1010

1111
import _ from 'lodash';
1212
import moment from 'moment';
@@ -60,6 +60,8 @@ export default class SplitRoute extends React.Component {
6060
strict,
6161
} = this.props;
6262

63+
const PUBLIC_PATH = global.TRU_BUILD_INFO.publicPath;
64+
6365
const timestamp = moment(buildTimestamp()).valueOf();
6466

6567
const { component } = this.state;

0 commit comments

Comments
 (0)