Skip to content

[Bug report] personal theme set 'layouts/Layout.vue' to main field can not load index.styl #2178

Open
@yiliang114

Description

@yiliang114
  • I confirm that this is an issue rather than a question.

Bug report

Steps to reproduce

you can see the package.json for my theme, if i just yarn start in local , maybe the package.json is not necessary. Thetheme/index.js in my theme is almost empty. And only do that as shown above, my theme can only to load index.styl automatically.

if i remove theme/index.js and set the "main" field to layouts/Layout.vue in package.json from the reference , after i run npm publish and install the latest theme, the style can not be load in the page.

What is expected?

set the "main" field to layouts/Layout.vue in package.json from the reference and publish my theme, people who installed the latest theme can load style correctly

What is actually happening?

theme may lose some style , due to the index.styl could not load automatically

Other relevant information

  • Output of npx vuepress info in my VuePress project:

Environment Info:

System:
OS: macOS Mojave 10.14.6
CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz
Binaries:
Node: 10.15.2 - /usr/local/bin/node
Yarn: 1.22.0 - ~/.yarn/bin/yarn
npm: 6.9.0 - /usr/local/bin/npm
Browsers:
Chrome: 80.0.3987.100
Firefox: 71.0
Safari: 13.0.4
npmPackages:
@vuepress/core: 1.3.0
@vuepress/theme-default: 1.3.0
vuepress: ^1.2.0 => 1.3.0
npmGlobalPackages:
vuepress: 1.2.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions