function addDisplayPageConfig(pages, sourceDir, configFile) {
    let path = relative(configFile.fullPath, sourceDir);
    let {pageName} = getPageInfo(path);
    let currPageDisplayInfo = pages[pageName];
    let pageConfig = JSON.parse(configFile.content);

    let result = {};
    // filter the illegal not supported config item
    // and map the weixin config name to quick app
    Object.keys(pageConfig).forEach(k => {
        let newKey = DISPLAY_PAGE_CONFIG_MAP[k];
        if (newKey) {
            result[newKey] = pageConfig[k];
        }
    });

    // merge the page config, the config defined in page has higher priority
    // than the app config
    pages[pageName] = Object.assign({}, currPageDisplayInfo, result);
}
function addDisplayPageConfig(pages, sourceDir, configFile) {
    let path = relative(configFile.fullPath, sourceDir);
    let {pageName} = getPageInfo(path);
    let currPageDisplayInfo = pages[pageName];
    let pageConfig = JSON.parse(configFile.content);

    let result = {};
    
    
    Object.keys(pageConfig).forEach(k => {
        let newKey = DISPLAY_PAGE_CONFIG_MAP[k];
        if (newKey) {
            result[newKey] = pageConfig[k];
        }
    });

    
    
    pages[pageName] = Object.assign({}, currPageDisplayInfo, result);
}
function addDisplayPageConfig ( pages , sourceDir , configFile ) { let path = relative ( configFile . fullPath , sourceDir ) ; let { pageName } = getPageInfo ( path ) ; let currPageDisplayInfo = pages [ pageName ] ; let pageConfig = JSON . parse ( configFile . content ) ; let result = { } ; // filter the illegal not supported config item // and map the weixin config name to quick app Object . keys ( pageConfig ) . forEach ( k => { let newKey = DISPLAY_PAGE_CONFIG_MAP [ k ] ; if ( newKey ) { result [ newKey ] = pageConfig [ k ] ; } } ) ; // merge the page config, the config defined in page has higher priority // than the app config pages [ pageName ] = Object . assign ( { } , currPageDisplayInfo , result ) ; }
Add display page config info based the config defined in page

@inner
@param {Object} pages the existed display page config
@param {string} sourceDir the project source directory
@param {Object} configFile the config file
Add display page config info based the config defined in page