File tree Expand file tree Collapse file tree 3 files changed +8
-7
lines changed
Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ export const staticFolder =
44export const renderOutputFolder = 'dist/views' ;
55export const publicPath = '/assets' ;
66export const iconCdnUrl = '//dkny.oss-cn-hangzhou.aliyuncs.com/1/icons' ;
7- export const directImgGrpNum = 2 ;
7+ export const nonLazyImg = 2 ;
88export const author = 'ZJ Guo' ;
99export const githubUrl = 'https://github.com' ;
1010export const gitRepo = `${ githubUrl } /im6/javascript-fun` ;
@@ -16,7 +16,7 @@ export const defaultIcon = [
1616 'github4.png' ,
1717] [ 0 ] ;
1818export const leftNavText = [
19- new Date ( ) . getFullYear ( ) ,
19+ new Date ( ) . getFullYear ( ) + ( new Date ( ) . getMonth ( ) < 11 ? 0 : 1 ) ,
2020 'Developer' ,
2121 'Designer' ,
2222 'Architect' ,
Original file line number Diff line number Diff line change 11import React from 'react' ;
22import PropTypes from 'prop-types' ;
33
4- import AppContainer from '../../components/AppContainer' ;
5- import BoxGroup from '../../components/BoxGroup' ;
64import GitBox from '../../components/GitBox' ;
5+ import BoxGroup from '../../components/BoxGroup' ;
6+ import AppContainer from '../../components/AppContainer' ;
77
88import style from './style.less' ;
99import sharedStyle from '../style.less' ;
10- import { directImgGrpNum } from '../../config' ;
10+ import { nonLazyImg } from '../../config' ;
1111
1212const GitPage = ( {
1313 url,
@@ -20,7 +20,7 @@ const GitPage = ({
2020 < AppContainer url = { url } criticalCss = { criticalCss } >
2121 < div className = { sharedStyle . main } >
2222 { source . map ( ( v , k ) => {
23- const lazyLoad = k > directImgGrpNum ;
23+ const lazyLoad = k > nonLazyImg ;
2424 return (
2525 < BoxGroup key = { v . id } title = { v . name } >
2626 { v . list . map ( v1 => (
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import {
1111 defaultIcon ,
1212 pageLink ,
1313 renderOutputFolder ,
14- viewModelPath
14+ viewModelPath ,
1515} from '../config' ;
1616
1717const gitCssDir = 'dist/public/main.css' ;
@@ -55,6 +55,7 @@ const generateSitePage = url => {
5555} ;
5656
5757if ( ! fs . existsSync ( renderOutputFolder ) ) {
58+ fs . mkdirSync ( renderOutputFolder ) ;
5859 fs . mkdirSync ( `${ renderOutputFolder } /node` ) ;
5960 fs . mkdirSync ( `${ renderOutputFolder } /library` ) ;
6061 fs . mkdirSync ( `${ renderOutputFolder } /site` ) ;
You can’t perform that action at this time.
0 commit comments