Skip to content

Commit

Permalink
[website]: Fix broken help link on homepage (#7706)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattphillips authored and SimenB committed Jan 25, 2019
1 parent 7bcb2c7 commit a7cbeb6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

### Fixes

- `[website]` Fix broken help link on homepage ([#7706](https://github.com/facebook/jest/pull/7706))

### Chore & Maintenance

### Performance
Expand Down
10 changes: 6 additions & 4 deletions website/pages/en/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ const GridBlock = CompLibrary.GridBlock;
const translate = require('../../server/translate.js').translate;
const backers = require(process.cwd() + '/backers.json');
const siteConfig = require(process.cwd() + '/siteConfig.js');
const getUrl = (url, language) => siteConfig.baseUrl + 'docs/' + language + url;
const getDocsUrl = (url, language) =>
siteConfig.baseUrl + 'docs/' + language + url;
const getUrl = (url, language) => siteConfig.baseUrl + language + url;

class Button extends React.Component {
render() {
Expand Down Expand Up @@ -235,13 +237,13 @@ const HeroInteractive = ({config: {repoUrl}, language}) => (
</div>
<Hand />
<div className="jest-button-container">
<Button href={getUrl('/getting-started.html', language)}>
<Button href={getDocsUrl('/getting-started.html', language)}>
<translate>Get Started</translate>
</Button>
<Button href={getUrl('/getting-started.html', language)}>
<Button href={getDocsUrl('/getting-started.html', language)}>
<translate>Docs</translate>
</Button>
<Button href={getUrl('/configuration', language)}>
<Button href={getDocsUrl('/configuration', language)}>
<translate>Config</translate>
</Button>
<Button href={getUrl('/help', language)}>
Expand Down

0 comments on commit a7cbeb6

Please sign in to comment.