Skip to content

when add the head configuration like favicon in the .config.js, build error。 #2620

@Jinwan5290

Description

@Jinwan5290

code as follows
module.exports = { base: '/docs/', title: 'mrapi', description: 'mrapi docs', head: ['link', { rel: 'icon', href: '/assets/favico.ico' }], ... }
and dev is ok
but when i build
The error occurred:
`
TypeError: undefined is not a function
at /Users/jinwan/Desktop/work-project/mrapi-docs/node_modules/@vuepress/core/lib/node/build/index.js:101:15
at Array.filter ()
at Build.render (/Users/jinwan/Desktop/work-project/mrapi-docs/node_modules/@vuepress/core/lib/node/build/index.js:101:8)
at async App.build (/Users/jinwan/Desktop/work-project/mrapi-docs/node_modules/@vuepress/core/lib/node/App.js:499:5)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

`
then I enter the source code to view
and see
image
in the debug
we can see there is no function called userHeadTags on the this instance
image
so how can solve this

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions