Skip to content

Commit

Permalink
docs: update features (#360)
Browse files Browse the repository at this point in the history
Co-authored-by: Anthony Fu <anthonyfu117@hotmail.com>
  • Loading branch information
arashsheyda and antfu authored Aug 6, 2023
1 parent ce53651 commit 761b349
Show file tree
Hide file tree
Showing 2 changed files with 83 additions and 7 deletions.
14 changes: 14 additions & 0 deletions docs/content/1.guide/0.index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,20 @@
Nuxt DevTools requires **Nuxt v3.1.0 or higher**.
::

### Auto Install

You just need to go to your `nuxt.config` file and set `devtools` to `true`:

```ts [nuxt.config.ts]
export default defineNuxtConfig({
devtools: { enabled: true },
})
```

Nuxt will automatically install the DevTools module for you.

### Install using Nuxi

You can opt-in Nuxt DevTools per-project by going to the project root and run:

```bash
Expand Down
76 changes: 69 additions & 7 deletions docs/content/1.guide/1.features.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@ Discover it in video with a video from [LearnVue](https://go.learnvue.co):

## Overview

Shows a quick overview of your app, including the Nuxt version, the pages, the components, the modules, and the plugins you are using. In the future we will add more, and allow you to upgrade your Nuxt with a single click.
Shows a quick overview of your app, including the Nuxt version (which if it’s not up to date you can easily update it), Vue version, pages, components, imports, modules and plugins that you are using, and your app’s loading time and more!

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670797-12c33a03-ca4f-490d-a18a-ab9008b89c15.png">

## Pages

Pages tab shows your current routes, and provide a quick way to navigate to them. You can also use the textbox to see how each route is matched.
Pages tab shows your current routes with some useful information such as what layout or middleware it has, and provides a quick way to navigate between pages. You can also use the textbox to see how each route is matched.

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670804-e48482af-de37-47be-88d8-d9515e796d5f.png">


## Components

Components tab show all the components you are using in your app and where they are from. You can also search for them and go to the source code.
Components tab shows all the components you are using in your app and where they are from. You can also search for them and go to the source code.

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670805-726eafd1-5364-4b11-9c2b-9253d068e7e3.png">

The graph view also show the relationship beetwen components, and know the dependencies of each component.
Components tab also has a Graph view which you can toggle.
Graph view also shows the relationship between components, and knows the dependencies of each component.

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670806-fb39aeff-3881-44e5-b9c8-6c757f5925fc.png">

You can also inspect your app's DOM tree and see which component is rendering it. Find the place to make changes are much easier.
You can also inspect your app's DOM tree and see which component is rendering it. Finding the place to make changes are much easier.

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670809-7dcb4198-5a74-4818-95b1-b62ea6c04a6c.png">

Expand All @@ -43,10 +43,52 @@ Imports tab shows all the auto-imports registered to Nuxt. You can see which fil

## Modules

Modules tab shows all the modules you have installed and the links to their documentation. In the future, we will try to provide a visual UI to install new modules with one-click.
Modules tab shows all the modules you have installed and their information such as the module’s github repository, documentation, version and …

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670813-ce3da4b6-269c-430e-abb5-a2263ffe4938.png">

You can install or even remove any Nuxt module with one-click!

## Assets

Assets tab shows your files from the Public directory, you can see the information of selected file with some helpful actions.

You can also upload files with Drag & Drop ability

## Terminals

Terminals tab shows the active terminal processes.

## Runtime Config

Runtime Config tab shows all the runtime config of your project, with the ability to edit them.

## Payload

Payloads tab shows all the state and data payloads of your project.

## Build Analyze

In the Build Analyze tab, you can run analyze build and see the bundle size of your project. it saves the report so you can compare the bundle size in different builds.

## Open Graph

Open Graph tab is to help you with SEO, it shows you a Social Preview Card for twitter, facebook and linkedIn for your page. It also provides missing SEO tags with the ability to copy code snippets.

## Plugins

Plugins tab shows all the plugins your project is using, with some information such as plugin's initialization time.

## Server Routes

Server Routes tab shows all nitro routes in your project. It provides a playground to send and test your endpoints.

## Storage

Storage tab shows all the nitro storage in your project. You can create, edit, and delete files.

Learn more about [Nitro Storage](https://nitro.unjs.io/guide/storage)

## Hooks

Hooks tab can help you to monitor the time spent in each hook. It can be helpful to find performance bottlenecks.
Expand All @@ -64,3 +106,23 @@ Virtual Files tab shows the virtual files generated by Nuxt to support the conve
Inspect expose the [`vite-plugin-inspect`](https://github.com/antfu/vite-plugin-inspect) integration, allowing you to inspect transformation steps of Vite.

<img width="1284" src="https://user-images.githubusercontent.com/11247099/217670818-77f91135-7318-462e-9148-4ad504c82555.png">

## Settings

Settings tab allows you to configure the DevTools to your needs. you can hide tabs, change tabs order, scale, theme and more...

## Nuxt Icon

Nuxt Icon is the first item on sidebar, located at the top left corner of the DevTools. It gives you a quick access to some useful features such as `Toggle Theme`, `Settings`, `Split Screen`, `Popup`, `Refresh Data`, `Refresh Page`. you can simply click on it and see the them yourself.

### Command Palette

Command Palette is a quick way to access some useful features of the DevTools such as easy navigation, run commands and Nuxt Documentations. You can open it with `Ctrl+Shift+K` or `Cmd+Shift+K` shortcut.

### Split Screen

Split Screen is a useful feature to use multiple tabs at the same time. You can open it from `Command Palette` or by clicking the `Nuxt Icon` in the top left corner of the DevTools and activate it from there.

### Popup

Popup is very useful for those who has a second screen, you can open it by clicking the `Nuxt Icon` in the top left corner of the DevTools and activate it from there.

0 comments on commit 761b349

Please sign in to comment.