I'd like to control my maupassant configuration outside of the theme directory (see https://hexo.io/docs/configuration#Alternate-Theme-Config). For most of the settings this works fine. For the menu, widgets, and links settings, however, the resulting merged config makes it impossible to remove items.
For example. In my _config.maupassant.yaml file, I have the following:
widgets:
- search
- tag
- links
In the themes/maupassant/_config.yaml file, there is the following default:
widgets: ## Six widgets in sidebar provided: search, category, tag, recent_posts, rencent_comments and links.
- search
- category
- tag
- recent_posts
- recent_comments
- links
When I run hexo serve, I see the following list of widgets:
search ✔️
tag ✔️
links ✔️
recent_posts ❌
recent_comments ❌
links ❌
If I try appending - NULL to my lists, I get errors. The only workaround I've found so far is to comment out the contents in the themes/maupassant/_config.yaml file, but this obviously defeats the purpose.
I am sorry that I haven't used the alternate-theme-config of Hexo yet, so I cannot clarify the reason for your problems at present, maybe there are some syntax conflicts in those .pug files of the widgets.
I'd like to control my maupassant configuration outside of the theme directory (see https://hexo.io/docs/configuration#Alternate-Theme-Config). For most of the settings this works fine. For the menu, widgets, and links settings, however, the resulting merged config makes it impossible to remove items.
For example. In my
_config.maupassant.yaml
file, I have the following:In the
themes/maupassant/_config.yaml
file, there is the following default:When I run
hexo serve
, I see the following list of widgets:If I try appending
- NULL
to my lists, I get errors. The only workaround I've found so far is to comment out the contents in thethemes/maupassant/_config.yaml
file, but this obviously defeats the purpose.I'm using: