Skip to content
This repository has been archived by the owner on Apr 1, 2020. It is now read-only.

Rhys/use hashed bundle #987

Merged
merged 25 commits into from
Jun 26, 2017
Merged

Rhys/use hashed bundle #987

merged 25 commits into from
Jun 26, 2017

Conversation

wheresrhys
Copy link
Contributor

@wheresrhys wheresrhys commented Jun 23, 2017

Also contains a load of (hopefully) simplification of how paths to assets are built.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.9%) to 91.081% when pulling 8fed349 on rhys/use-hashed-bundle into 5936e48 on master.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.9%) to 91.081% when pulling 8ede16b on rhys/use-hashed-bundle into 5936e48 on master.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.9%) to 91.081% when pulling 9b528e5 on rhys/use-hashed-bundle into 5936e48 on master.

@coveralls
Copy link

Coverage Status

Coverage decreased (-1.0%) to 91.033% when pulling 8ecfffc on rhys/use-hashed-bundle into 5936e48 on master.

})
.then(text => {
// if it's an empty string, something probably went wrong
if (!text.length) {
throw new Error('Fetched empty n-ui stylesheet');
throw new Error('Fetched empty ${s3Name} from s3');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backticks

.then(res => {
if (res.ok) {
return res.text();
}
throw new Error('Failed to fetch n-ui stylesheet');
throw new Error('Failed to download ${s3Name} from s3');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backticks

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙀

const assetHashes = loadAssetHashesJson(`${directory}/public/asset-hashes.json`);
const nUiAssetHashes = loadAssetHashesJson(`${directory}/public/n-ui-asset-hashes.json`);
const nUiReleaseName = nUiManager.getReleaseName(directory);
const nUiUnhashedAssetsRoot = useLocalAppShell ? '/${appName}/n-ui/' : `//www.ft.com/__assets/n-ui/cached/${nUiReleaseName}/`;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backticks?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should probably add some tests for dev mode. Not in this PR though as it's already epic

@coveralls
Copy link

Coverage Status

Coverage decreased (-1.0%) to 91.008% when pulling 6b340a6 on rhys/use-hashed-bundle into 5936e48 on master.

@wheresrhys wheresrhys merged commit 87408a3 into master Jun 26, 2017
@leafrogers leafrogers deleted the rhys/use-hashed-bundle branch June 27, 2017 10:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants