Skip to content

docs: make inspector docs more scannable #991

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

Merged
merged 1 commit into from
Oct 13, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions docs/inspector.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,23 @@ Note that `@sveltejs/vite-plugin-svelte` needs to be installed as a peer depende

## Setup

### with Svelte config
### enable in Svelte config

```js
// svelte.config.js
export default {
vitePlugin: {
inspector: true
}
};
```

### enable with custom options in Svelte config

```js
// svelte.config.js
export default {
vitePlugin: {
// set to true for defaults or customize with object
inspector: {
toggleKeyCombo: 'meta-shift',
showToggleButton: 'always',
Expand All @@ -22,7 +32,7 @@ export default {
};
```

### with environment variables
### configure with environment variables

Svelte Inspector toggle keys and other options are personal preferences. As such it isn't always convenient to define them in a shared svelte config file.
To allow you to use your own setup, svelte inspector can be configured via environment variables, both from shell and dotenv files.
Expand Down