Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

get the wrong source path when directly enter subpages #12

Closed
ConyLuLu opened this issue Aug 1, 2024 · 2 comments
Closed

get the wrong source path when directly enter subpages #12

ConyLuLu opened this issue Aug 1, 2024 · 2 comments

Comments

@ConyLuLu
Copy link

ConyLuLu commented Aug 1, 2024

Thanks for this project. It's really convenient to use.
But I encountered some problems while developing, I'd be grateful if you could help.

This is my pages structure:

|--/pages
|---/contract
| |--index.vue
| |--contractInfo.vue

nuxt.config

  modules: [
      '@coremyslo/nuxt-icon-font',
  ],

  iconFont: {
    // Font name to be used in "font-family" and custom properties generated prefix "--icon-font-svgiconfilename"
    name: "icon-font",
    // folder with icons to watch
    sourceDirPath: "assets/icon-font",
    // target folder for generated fonts in "public" folder
    targetDirPath: "icon-font",
    // font formats to generate, fallback to ["woff2"] in case browserslist is not used, example for manual configuration: ["svg", "ttf", "woff", "woff2", "eot"] in any order
    formats: ["svg"],
    // Support of generating the most popular font as base64
    base64: false,
    // unicode symbol for first icon in iconfont (makes sense to change only if you're not going to use custom properties)
    unicode: "0xE900",
    // generated custom properties (variables) format. Other options are: "snake", "pascal", "camel", "header", "constant"
    case: "kebab"
  },

I can display the icon correctly on the contract page, but on contractInfo page I got this error message after refresh:
(Page not found: /contract/icon-font/icon-font.woff2?afb75685-4165-5b18-b513-863da7b76d11)

It seems get the wrong path when directly enter subpages.

@coremyslo
Copy link
Owner

Thanks for reporting.
Should be fixed in #17
Released in 1.2.0 version

@ConyLuLu
Copy link
Author

ConyLuLu commented Aug 5, 2024

@coremyslo Thanks a bunch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants