sanity-plugin-seo-copilot 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +50 -0
- package/dist/index.d.mts +9 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.js +2706 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +2671 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +56 -0
- package/sanity.json +3 -0
- package/src/components/ChatPanel.tsx +291 -0
- package/src/components/ConfigContext.tsx +22 -0
- package/src/components/FeedbackButton.tsx +208 -0
- package/src/components/KeywordBadge.tsx +50 -0
- package/src/components/KeywordPanel.tsx +1165 -0
- package/src/components/PlacementIndicators.tsx +76 -0
- package/src/components/SEOCopilotPanel.tsx +550 -0
- package/src/components/SeedKeywordInput.tsx +125 -0
- package/src/components/styles.ts +77 -0
- package/src/hooks/useDocumentContent.ts +99 -0
- package/src/hooks/useKeywordAnalysis.ts +225 -0
- package/src/hooks/useSEOChat.ts +169 -0
- package/src/index.ts +16 -0
- package/src/inspector.ts +51 -0
- package/src/lib/api.ts +175 -0
- package/src/lib/types.ts +108 -0
- package/v2-incompatible.js +10 -0
package/README.md
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# sanity-plugin-seo-copilot
|
|
2
|
+
|
|
3
|
+
AI-powered SEO writing assistant for Sanity Studio v3.
|
|
4
|
+
|
|
5
|
+
Adds an SEO Copilot inspector panel to every document in your Sanity Studio. Editors get real-time keyword analysis, search volume data, placement tracking, and an AI chat assistant - all without leaving the editor.
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
npm install sanity-plugin-seo-copilot
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Configuration
|
|
14
|
+
|
|
15
|
+
Add the plugin to your `sanity.config.ts`:
|
|
16
|
+
|
|
17
|
+
```ts
|
|
18
|
+
import { defineConfig } from 'sanity'
|
|
19
|
+
import { seoCopilot } from 'sanity-plugin-seo-copilot'
|
|
20
|
+
|
|
21
|
+
export default defineConfig({
|
|
22
|
+
// ... your existing config
|
|
23
|
+
plugins: [
|
|
24
|
+
// ... your existing plugins
|
|
25
|
+
seoCopilot({
|
|
26
|
+
apiUrl: 'https://ecaruso.vercel.app',
|
|
27
|
+
publication: 'Your Publication Name', // optional
|
|
28
|
+
}),
|
|
29
|
+
],
|
|
30
|
+
})
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Options
|
|
34
|
+
|
|
35
|
+
| Option | Type | Required | Description |
|
|
36
|
+
| ------------- | ------ | -------- | ------------------------------------------------ |
|
|
37
|
+
| `apiUrl` | string | Yes | Backend API URL for SEO analysis |
|
|
38
|
+
| `publication` | string | No | Publication name for tailored keyword suggestions |
|
|
39
|
+
|
|
40
|
+
## Usage
|
|
41
|
+
|
|
42
|
+
Once installed, every document in your Studio gets an SEO Copilot icon in the toolbar. Click it to open the inspector panel with:
|
|
43
|
+
|
|
44
|
+
- **Keywords tab** - Real-time keyword analysis with search volume data, placement indicators (body, title, description, image, URL), and AI-suggested keywords
|
|
45
|
+
- **Chat tab** - AI assistant that understands your document content and can help with SEO strategy, title suggestions, meta descriptions, and more
|
|
46
|
+
|
|
47
|
+
## How it works
|
|
48
|
+
|
|
49
|
+
The plugin reads document content from the Sanity editor and sends it to the backend API for analysis. The backend uses Claude AI for keyword analysis and SEMrush for search volume data. All processing happens server-side - the plugin itself is a lightweight UI.
|
|
50
|
+
|
package/dist/index.d.mts
ADDED