|
| 1 | +<p align="center"> |
| 2 | + <img src="https://ikun-ui.netlify.app/logo.svg" width="180" height="180"/> |
| 3 | +</p> |
| 4 | +<h1 align="center"> |
| 5 | +ikun-svelte-devtools |
| 6 | +</h1> |
| 7 | +<p align="center"> |
| 8 | +🍨 A vite plugin that improves the svelte development experience |
| 9 | +</p> |
| 10 | + |
| 11 | + |
| 12 | +## Features |
| 13 | + |
| 14 | + |
| 15 | + |
| 16 | +### page |
| 17 | + |
| 18 | +In the pages module, you can quickly understand which pages the project contains |
| 19 | + |
| 20 | + |
| 21 | + |
| 22 | +### Routes |
| 23 | +In the Routes module, you can quickly understand the routing information of the project |
| 24 | + |
| 25 | + |
| 26 | + |
| 27 | +### Assets |
| 28 | +In the Assets module, you can quickly understand the static resources of the project, including pictures, fonts, etc. |
| 29 | + |
| 30 | + |
| 31 | + |
| 32 | +### Search Packages |
| 33 | +In the Search Packages module you can search for dependencies and install or uninstall them |
| 34 | + |
| 35 | + |
| 36 | + |
| 37 | +### Inspect |
| 38 | +In the Inspect module you can view the compiled code, It comes from `vite-plugin-inspect` support. |
| 39 | + |
| 40 | + |
| 41 | + |
| 42 | +### Graph |
| 43 | +In the Graph module, you can quickly understand the reference relationship between js and sfc through visualization |
| 44 | + |
| 45 | + |
| 46 | + |
| 47 | +### Inspector |
| 48 | +In the Inspector module, you can click on an element on the page to open the corresponding source code in the IDE. |
| 49 | +It comes from `svelte-kit-inspector` support. |
| 50 | + |
| 51 | + |
| 52 | +### EyeDropper |
| 53 | +EyeDropper module can open a color picker |
| 54 | + |
| 55 | +## Install |
| 56 | + |
| 57 | +```bash |
| 58 | +npm i @ikun-svelte-devtools/server -D |
| 59 | +``` |
| 60 | +Or |
| 61 | +```bash |
| 62 | +yarn add @ikun-svelte-devtools/server -D |
| 63 | +``` |
| 64 | +Or |
| 65 | +```bash |
| 66 | +pnpm add @ikun-svelte-devtools/server -D |
| 67 | +``` |
| 68 | + |
| 69 | +## Usage |
| 70 | +```ts |
| 71 | +// vite.config.ts |
| 72 | +import { sveltekit } from '@sveltejs/kit/vite'; |
| 73 | +import { defineConfig } from 'vite'; |
| 74 | +import svelteDevtools from '@ikun-svelte-devtools/server'; |
| 75 | +export default defineConfig({ |
| 76 | + plugins: [ |
| 77 | + svelteDevtools({ |
| 78 | + sveltekit: sveltekit() |
| 79 | + }), |
| 80 | + ], |
| 81 | +}); |
| 82 | + |
| 83 | +``` |
| 84 | +## Thanks |
| 85 | + |
| 86 | +- [svelte](https://github.com/sveltejs/svelte) |
| 87 | +- [unocss](https://github.com/nuxt/devtools) |
| 88 | +- [vite-plugin-vue-devtools](https://github.com/webfansplz/vite-plugin-vue-devtools) |
0 commit comments