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

Can't find type declaration file #105

Open
2 tasks done
Luvdduk opened this issue Jul 17, 2024 · 1 comment
Open
2 tasks done

Can't find type declaration file #105

Luvdduk opened this issue Jul 17, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@Luvdduk
Copy link

Luvdduk commented Jul 17, 2024

Checks

Version

0.6.12

Description

when import splide, vs code can't find type declaration of Splide.
image

so I add this "types": "./src/js/index.ts" in exports

like this

{
  "exports": {
      ".": {
        "require": "./dist/js/vue-splide.cjs.js",
        "import": "./dist/js/vue-splide.esm.js",
        "default": "./dist/js/vue-splide.esm.js",
        "types": "./src/js/index.ts"
      },
      "./css": "./dist/css/splide.min.css",
      "./css/core": "./dist/css/splide-core.min.css",
      "./css/*": "./dist/css/themes/splide-*.min.css"
    },
}

then it will be fixed

Reproduction Link

No response

Steps to Reproduce

  1. import { Splide } from '@splidejs/vue-splide'; in vscode

...

Expected Behaviour

image

@Luvdduk Luvdduk added the bug Something isn't working label Jul 17, 2024
@jedso
Copy link

jedso commented Jul 22, 2024

This is a duplicate of #91, and there's an open PR here to fix it #92. Hopefully it will get merged soon 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants