Skip to content

Commit

Permalink
chore: draft readme
Browse files Browse the repository at this point in the history
  • Loading branch information
antfu committed Jan 23, 2023
1 parent 7f633c2 commit 9fab4a0
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 2 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 Nuxt Team
Copyright (c) 2022-PRESENT Nuxt Team

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
54 changes: 54 additions & 0 deletions README.prepare.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# Nuxt DevTools <sup>Alpha Preview</sup>

Tools to enhance your development experience with Nuxt. Transparent, infomative, extensible and joyful.

> **Note**: Experimental and under heavy development. APIs are subject to change.
## Installation

Nuxt DevTools is currently only available in edge versions (releases on every commit to `main`).

Requires Nuxt 3.1.0 or higher.

```bash
npm i -D @nuxt/devtools-edge
```

```ts
// nuxt.config.ts
export default defineNuxtConfig({
modules: [
'@nuxt/devtools-edge',
],
})
```

Then open your app in browser. Click the Nuxt icon on the bottom to open the DevTools.

## Module Authors

Nuxt DevTools is designed to be extensible. You can add your own modules's integration to the DevTools.

> **Warning**: API and subject to change.
### Contributing to View

Currently the only way to contribute to Nuxt DevTools View is via iframe. You need to serve your module's view yourself and then register it to the DevTools.

```ts
nuxt.hook('devtools:customTabs', (tabs) => {
tabs.push({
name: 'my-module',
title: 'My Module',
icon: 'carbon:apps', // any icon name from Iconify
view: {
type: 'iframe',
src: '/url-to-your-module-view',
},
})
})
```

## License

[MIT](./LICENSE)
2 changes: 1 addition & 1 deletion client/components/ComposableItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const modules = $computed(() => metadata?.injectionUsage?.[name]?.moduleIds || [
<div border="t base" px4 py3>
<template v-if="usageCount">
<div text-sm>
<span op50>It has been referenced </span><strong text-primary>{{ usageCount }}</strong><span op50>times by:</span>
<span op50>It has been referenced </span><strong text-primary>{{ usageCount }}</strong><span op50> times by:</span>
</div>
<div flex="~ col gap-2" items-start pt3 text-sm>
<FilepathItem
Expand Down

0 comments on commit 9fab4a0

Please sign in to comment.