Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correction of bug in component #249

Merged
merged 2 commits into from
Apr 25, 2018
Merged

Conversation

luisDanielRoviraContreras
Copy link
Contributor

Correction of bug in component without having the key property

@ulivz
Copy link
Member

ulivz commented Apr 25, 2018

Thanks for fixing this!

Just a small thing, although I knew this context, but it's better to provide the context(e.g. How to repro) when you open a bug fixing PR, which is friendly to future review.

@ulivz
Copy link
Member

ulivz commented Apr 25, 2018

So I just can guess your config, I repro this bug with following nav config:

nav: [
  {
    text: 'Guide',
    link: '/guide/',
  },
  {
    text: 'Config Reference',
    link: '/config/'
  },
  {
    text: 'test',
    items: [
      {
        text: 'Guide',
        link: '/guide/',
      },
      {
        text: 'Config Reference',
        link: '',
        items: [
          {
            text: 'Guide',
            link: '/guide/',
          },
          {
            text: 'Config Reference',
            link: '/config/'
          }
        ]
      },
      {
        text: 'Config Reference',
        link: '',
        items: [
          {
            text: 'Guide',
            link: '/guide/',
          },
          {
            text: 'Config Reference',
            link: '/config/'
          }
        ]
      }
    ]
  },
  {
    text: 'Default Theme Config',
    link: '/default-theme-config/'
  }
]

In fact, you can just remove the empty link (link: '') to fix it, but this PR is valuable. thanks!

@luisDanielRoviraContreras
Copy link
Contributor Author

To reproduce the error you have to put in .vuepress / config.js the empty links inside nav in this case

@ulivz ulivz merged commit 1417a35 into vuejs:master Apr 25, 2018
@ulivz ulivz mentioned this pull request May 11, 2018
@ulivz
Copy link
Member

ulivz commented May 11, 2018

Will release it at 0.9.0: #419. 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants