mirror of
https://github.com/youzan/vant.git
synced 2025-10-22 11:54:02 +00:00
[Doc] support doc search
This commit is contained in:
@@ -4,7 +4,9 @@
|
||||
:base="base"
|
||||
:config="config"
|
||||
active="Vue 组件"
|
||||
:lang="$vantLang"
|
||||
:simulators="simulators"
|
||||
:search-config="searchConfig"
|
||||
:current-simulator="currentSimulator"
|
||||
>
|
||||
<router-view @changeDemoURL="onChangeDemoURL" />
|
||||
@@ -17,6 +19,7 @@ import docConfig from './doc.config';
|
||||
|
||||
export default {
|
||||
data() {
|
||||
this.searchConfig = docConfig.searchConfig;
|
||||
return {
|
||||
simulators: [`mobile.html${location.hash}`],
|
||||
demoURL: ''
|
||||
|
@@ -2,12 +2,15 @@
|
||||
const version = require('../../package.json').version;
|
||||
|
||||
module.exports = {
|
||||
searchConfig: {
|
||||
apiKey: '90067aecdaa2c85220e2783cd305caac',
|
||||
indexName: 'vant',
|
||||
},
|
||||
'zh-CN': {
|
||||
header: {
|
||||
logo: {
|
||||
image: 'https://img.yzcdn.cn/public_files/2017/12/18/fd78cf6bb5d12e2a119d0576bedfd230.png',
|
||||
title: 'Vant',
|
||||
version,
|
||||
href: '#/'
|
||||
},
|
||||
nav: {
|
||||
@@ -342,7 +345,6 @@ module.exports = {
|
||||
logo: {
|
||||
image: 'https://img.yzcdn.cn/public_files/2017/12/18/fd78cf6bb5d12e2a119d0576bedfd230.png',
|
||||
title: 'Vant',
|
||||
version,
|
||||
href: '#/'
|
||||
},
|
||||
nav: {
|
||||
|
Reference in New Issue
Block a user