docs(website): add main link to introduction

This commit is contained in:
Miralem Drek
2020-05-13 18:50:21 +02:00
parent 0cc5572b12
commit d56172cb0a
2 changed files with 9 additions and 4 deletions

View File

@@ -100,7 +100,7 @@ Add a dimension by clicking on **Add dimension** and selecting a value in the me
In order to render the data you first need to access it through the `useLayout` hook:
```js
import { useElement, useLayout } from `@nebula.js/stardust`;
import { useElement, useLayout } from '@nebula.js/stardust';
// ...
component() {

View File

@@ -11,9 +11,14 @@ const {
class Index extends React.Component {
render() {
// const { config: siteConfig, language = '' } = this.props;
// const { baseUrl } = siteConfig;
const { baseUrl, docsUrl } = this.props.config;
const Block = props => (
const docUrl = (doc) => {
const docsPart = `${docsUrl ? `${docsUrl}/` : ''}`;
return `${baseUrl}${docsPart}${doc}`;
};
const Block = (props) => (
<Container padding={['bottom', 'top']} id={props.id} background={props.background}>
<GridBlock align="center" contents={props.children} layout={props.layout} />
</Container>
@@ -25,7 +30,7 @@ class Index extends React.Component {
<Block>
{[
{
title: 'Under construction',
title: `[Getting Started](${docUrl('introduction')})`,
},
]}
</Block>