x64Bits / solid-icons

The simplest way to use icons in SolidJS
https://solid-icons.vercel.app
MIT License
284 stars 18 forks source link

"lib" vite import error #62

Open jamtycle opened 2 months ago

jamtycle commented 2 months ago

Issue Description

importing "solid-icons/lib" using vite (import { CustomIcon } from 'solid-icons/lib';) yields [vite] Internal server error: Missing "./lib" specifier in "solid-icons" package.

image

An export may be missing on the lib package.

Edit:

It appears that import { CustomIcon } from 'solid-icons'; does work, it will be greatly appreciated a change in the README Custom Icon example to avoid confusion. 😄 👍🏼

package.json

{
  "name": "vite-template-solid",
  "version": "0.0.0",
  "description": "",
  "scripts": {
    "start": "vite --host",
    "dev": "vite",
    "build": "vite build",
    "serve": "vite preview"
  },
  "license": "MIT",
  "devDependencies": {
    "typescript": "^5.1.3",
    "vite": "^4.3.9",
    "vite-plugin-solid": "^2.7.0"
  },
  "dependencies": {
    "solid-icons": "^1.1.0",
    "solid-js": "^1.7.6"
  }
}

Reproduction Link

https://stackblitz.com/edit/github-3drhwq-q9vwbm?file=src%2FApp.tsx