Skip to content

Commit 4b86098

Browse files
authored
Merge pull request #321 from pluginpal/feat/add-documentation
Feat/add documentation
2 parents acfe8bc + 07ca757 commit 4b86098

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+987
-63
lines changed

.changeset/green-wasps-follow.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"docs": minor
3+
---
4+
5+
docs: add docs for the cli specifically

.changeset/wide-lies-enter.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"docs": minor
3+
---
4+
5+
docs: add docs for the Links addon, Redirects addon and enhance the docs in general

README.md

Lines changed: 57 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,59 @@
11
<div align="center">
2-
<h1>Strapi Webtools</h1>
3-
4-
<p style="margin-top: 0;">Everything you need to build a website with Strapi CMS</p>
5-
6-
<a href="https://docs.pluginpal.io/webtools">Read the documentation</a>
7-
8-
<p>
9-
<a href="https://www.npmjs.org/package/strapi-plugin-webtools">
10-
<img src="https://img.shields.io/npm/v/strapi-plugin-webtools/latest.svg" alt="NPM Version" />
11-
</a>
12-
<a href="https://www.npmjs.org/package/strapi-plugin-webtools">
13-
<img src="https://img.shields.io/npm/dm/strapi-plugin-webtools" alt="Monthly download on NPM" />
14-
</a>
15-
<a href="https://codecov.io/gh/pluginpal/strapi-webtools">
16-
<img src="https://img.shields.io/github/actions/workflow/status/pluginpal/strapi-webtools/tests.yml?branch=master" alt="CI build status" />
17-
</a>
18-
<a href="https://codecov.io/gh/pluginpal/strapi-webtools">
19-
<img src="https://codecov.io/gh/pluginpal/strapi-webtools/coverage.svg?branch=master" alt="codecov.io" />
20-
</a>
21-
</p>
22-
2+
<h1>Strapi Webtools</h1>
3+
<p style="margin-top: 0;">Everything you need to build a website with Strapi CMS</p>
4+
5+
<p>
6+
<a href="https://docs.pluginpal.io/webtools"><strong>Read the documentation →</strong></a>
7+
</p>
8+
9+
<p>
10+
<a href="https://www.npmjs.org/package/strapi-plugin-webtools">
11+
<img src="https://img.shields.io/npm/v/strapi-plugin-webtools/latest.svg" alt="NPM Version" />
12+
</a>
13+
<a href="https://www.npmjs.org/package/strapi-plugin-webtools">
14+
<img src="https://img.shields.io/npm/dm/strapi-plugin-webtools" alt="Monthly download on NPM" />
15+
</a>
16+
<a href="https://img.shields.io/github/actions/workflow/status/pluginpal/strapi-webtools/tests.yml?branch=master">
17+
<img src="https://img.shields.io/github/actions/workflow/status/pluginpal/strapi-webtools/tests.yml?branch=master" alt="CI build status" />
18+
</a>
19+
<a href="https://codecov.io/gh/pluginpal/strapi-webtools">
20+
<img src="https://codecov.io/gh/pluginpal/strapi-webtools/coverage.svg?branch=master" alt="codecov.io" />
21+
</a>
22+
</p>
2323
</div>
2424

25+
---
26+
2527
## ✨ Features
2628

27-
- **Unique URLs** Every page will get their own unique path
28-
- **Auto generated** Automatically generated based on a pattern
29-
- **Flexible** Overwrite single URLs
30-
- **Frontend router** Get any page by it's unique path from the public API
31-
- **Auto slugify** The URLs will automatically be slugified to ensure valid paths
29+
- Unique URLsEvery page gets its own unique path
30+
- Auto-generated – Based on a configurable URL pattern
31+
- Flexible – Override individual URLs when needed
32+
- Frontend router – Fetch any page by its unique path via the public API
33+
- Auto-slugify – Ensures valid, clean URL paths
3234

33-
## ⏳ Installation
35+
## ✅ Requirements
3436

35-
[Read the Getting Started tutorial](https://docs.pluginpal.io/webtools) or follow the steps below:
37+
- Node.js: >= 18.17
38+
- Strapi: v5.x
3639

37-
### Installer wizard
40+
## ⏳ Installation
3841

39-
To provide easy installation, this plugin comes with it's own installer wizard. It let's you interactively select which content types you want to enable and which addons you want to install. Making it easy to get started with Webtools!
42+
Read the full Getting Started guide in the docs, or run the installer. The command below executes the Webtools installer (webtools-cli) in your current project directory:
4043

4144
```bash
4245
npx webtools-cli install
4346
```
4447

45-
### Enabling
48+
The installer lets you:
49+
- Enable Webtools for selected content types
50+
- Optionally install addons (e.g. Sitemap)
4651

47-
Using the installer wizard you can easily enable Webtools for your content types. If there are still more content-types you want to enable, you can do that manually through the admin panel. Read more about how to do that in the [usage documentation](https://docs.pluginpal.io/webtools/usage).
52+
> Keyboard shortcuts: Space (toggle), a (all), i (invert), Enter (confirm)
4853
49-
### Building
54+
### Build the admin
5055

51-
After successful installation you have to rebuild the admin UI so it'll include this plugin. To rebuild and restart Strapi run:
56+
After installation, rebuild the Strapi admin so it includes the plugin:
5257

5358
```bash
5459
# using yarn
@@ -60,32 +65,36 @@ npm run build
6065
npm run develop
6166
```
6267

63-
Enjoy 🎉
68+
## 🚀 Quick start
6469

65-
## 📓 Documentation
70+
1) Enable Webtools for your content types (via the installer or Admin → Content-Type Builder)
71+
2) Create URL patterns (Webtools → Patterns)
72+
3) Bulk generate aliases (Webtools → All URLs)
73+
4) Optionally set up the Sitemap addon (see docs)
6674

67-
The full documentation of this plugin can be found on it's dedicated documentation website.
75+
Enjoy 🎉
6876

69-
- [Webtools core plugin](https://docs.pluginpal.io/webtools)
70-
- [Webtools sitemap addon](https://docs.pluginpal.io/webtools/addons/sitemap)
77+
## 📓 Documentation
7178

79+
- Core plugin: https://docs.pluginpal.io/webtools
80+
- Sitemap addon: https://docs.pluginpal.io/webtools/addons/sitemap
7281

7382
## 🔌 Addons
7483

75-
Webtools can be extended by installing addons that hook into the core Webtools functionality. Read more about how addons work and how to install them in the [addons documentation](https://docs.pluginpal.io/webtools/addons).
84+
Webtools can be extended with addons that hook into the core. Learn more: https://docs.pluginpal.io/webtools/addons
7685

7786
## 🔗 Links
7887

79-
- [PluginPal marketplace](https://www.pluginpal.io/plugin/webtools)
80-
- [NPM package](https://www.npmjs.com/package/strapi-plugin-webtools)
81-
- [GitHub repository](https://github.com/pluginpal/strapi-webtools)
82-
- [Strapi marketplace](https://market.strapi.io/plugins/@pluginpal-webtools-core)
88+
- PluginPal marketplace: https://www.pluginpal.io/plugin/webtools
89+
- NPM package: https://www.npmjs.com/package/strapi-plugin-webtools
90+
- GitHub repository: https://github.com/pluginpal/strapi-webtools
91+
- Strapi marketplace: https://market.strapi.io/plugins/@pluginpal-webtools-core
8392

8493
## 🌎 Community support
8594

86-
- For general help using Strapi, please refer to [the official Strapi documentation](https://strapi.io/documentation/).
87-
- You can contact me on the Strapi Discord [channel](https://discord.strapi.io/).
95+
- For Strapi usage questions, see the official docs: https://strapi.io/documentation/
96+
- Chat on Strapi Discord: https://discord.strapi.io/
8897

89-
## 📝 Resources
98+
## 📝 License
9099

91-
- [MIT License](https://github.com/pluginpal/strapi-webtools/blob/master/LICENSE.md)
100+
MIT https://github.com/pluginpal/strapi-webtools/blob/master/LICENSE.md

packages/docs/docs/addons/introduction.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,7 @@ Webtools is all about tools to enhance your website management workflow in Strap
1111
To enhance Webtools in a modular way, the core plugin allows addons to be registered to build upon it's functionalities. Addons are in Strapi terms just standalone plugins, but have `strapi-plugin-webtools` as a peer dependency. You will have to install each addon as you would normally install a plugin in to Strapi.
1212

1313
<CustomDocCardsWrapper>
14-
<CustomDocCard emoji="🔀" title="Sitemap" description="The Sitemap addon can be used to generate a customizable sitemap using all your Webtools URL aliases" link="/webtools/addons/sitemap" />
14+
<CustomDocCard emoji="🔌" title="Sitemap" description="The Sitemap addon can be used to generate a customizable sitemap using all your Webtools URL aliases" link="/webtools/addons/sitemap" />
15+
<CustomDocCard emoji="🔀" title="Redirects" description="The Redirects addon can be used to manage your redirects in Strapi CMS." link="/webtools/addons/redirects" />
16+
<CustomDocCard emoji="🔗" title="Links" description="The Links addon can be used create dynamic links from 1 page to another." link="/webtools/addons/links" />
1517
</CustomDocCardsWrapper>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
sidebar_label: 'Links format'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links/api/links-format
5+
---
6+
7+
# Rewrite middleware
8+
9+
This plugin stores the internal links in a specific format. That format looks something like this:
10+
11+
```
12+
wt-link://api::page.page/sp8bzbkn21pjy3m9wsf97dio
13+
```
14+
15+
This makes it possible to fetch the page, and ultimately the URL alias of the document that you have linked to.
16+
17+
The plugin also provides a middleware which will rewrite these link formats to the actual link when you're using the Strapi API.
18+
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
sidebar_label: 'Ckeditor'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links/ckeditor
5+
---
6+
7+
# Ckeditor integration
8+
This addon has an integration with [the Ckeditor plugin](https://github.com/nshenderov/strapi-plugin-ckeditor). If the Ckeditor plugin is installed this addon will replace the link button in the editor. With this new button you can create internal links in the ckeditor.
9+
10+
<img src="/webtools/img/assets/addons/links/ckeditor.png" alt="Ckeditor" />
11+
12+
If you click the link button it will open a modal in which you can manage your links.
13+
14+
<img src="/webtools/img/assets/addons/links/ckeditor-link-modal.png" alt="Ckeditor link modal" />
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
sidebar_label: 'Custom field'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links/custom-field
5+
---
6+
7+
# Custom field
8+
This addon introduces a new custom field which you can add to your content types. This field can be used in your content types to accommodate internal linking from one page to another.
9+
10+
<img src="/webtools/img/assets/addons/links/link-custom-field.png" alt="Link custom field" />
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
---
2+
sidebar_label: 'Installation'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links/installation
5+
---
6+
7+
# ⏳ Installation
8+
9+
:::prerequisites
10+
Complete installation requirements are the exact same as for Strapi itself and can be found in the Strapi documentation.
11+
12+
**Additional Requirements:**
13+
- **Node.js**: Version 18 or higher
14+
- **Strapi**: Version 5.x
15+
- **Webtools**: Version 1.x
16+
:::
17+
18+
:::caution
19+
This addon is part of the premium package of Webtools. You'll have to purchase a license key to download and use this package. Once you have your license key you can run the following command to setup your license in your project:
20+
21+
```
22+
npx webtools-cli setup-license
23+
```
24+
25+
To purchase a license, please visit the [PluginPal website](https://www.pluginpal.io/plugin/webtools).
26+
:::
27+
28+
### Installation
29+
30+
After you've setup your license you can install the addon like so:
31+
32+
<Tabs groupId="yarn-npm">
33+
<TabItem value="yarn" label="Yarn">
34+
```
35+
yarn add @pluginpal/webtools-addon-links
36+
```
37+
</TabItem>
38+
<TabItem value="npm" label="NPM">
39+
```
40+
npm install @pluginpal/webtools-addon-links --save
41+
```
42+
</TabItem>
43+
</Tabs>
44+
45+
After successful installation you have to rebuild the admin UI so it'll include this plugin. To rebuild and restart Strapi run:
46+
47+
<Tabs groupId="yarn-npm">
48+
<TabItem value="yarn" label="Yarn">
49+
```
50+
yarn build
51+
yarn develop
52+
```
53+
</TabItem>
54+
<TabItem value="npm" label="NPM">
55+
```
56+
npm run build
57+
npm run develop
58+
```
59+
</TabItem>
60+
</Tabs>
61+
62+
Enjoy 🎉
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
sidebar_label: 'Introduction'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links
5+
---
6+
7+
# Webtools Links Add-on
8+
9+
The **Links add-on** for Webtools Pro provides a powerful custom field type that allows content creators to easily create internal links within their Strapi CMS content. This field type streamlines the process of linking to other content entries, pages, or sections within your application.
10+
11+
:::note
12+
This plugin acts as an extension of the core `strapi-plugin-webtools`. Please install and configure that before proceeding.
13+
:::
14+
15+
## Key Features
16+
17+
- **🔗 Internal Link Management** - Easy selection of internal content for linking
18+
- **⚡ Custom field** - Add the link field to any content type
19+
- **⚡ Ckeditor integration** - Integrate the dynamic links in to your ckeditor
20+
- **🔍 Smart Search** - Find content quickly with built-in search functionality
21+
- **📝 Content Type Support** - Works with all your custom content types
22+
- **🎨 Intuitive UI** - Clean, user-friendly interface integrated with Strapi's design system
23+
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
sidebar_label: 'Link component'
3+
displayed_sidebar: webtoolsLinksSidebar
4+
slug: /addons/links/link-component
5+
---
6+
7+
# Link component
8+
This addon provides a custom field for you to create internal linking. It's good to note that the custom field only provides you a way to set the URL value of a link. We recommend you to create a Component in your Strapi application which combines all the attributes needed to create a link. This can also include the link text and other possible attributes like target.
9+
10+
This component can then be used to as a reference field anywhere you need it.
11+
12+
<img src="/webtools/img/assets/addons/links/link-component.png" alt="Link component" />
13+
14+
The schema of this link component can look something like this:
15+
16+
```
17+
{
18+
"collectionName": "components_core_links",
19+
"info": {
20+
"displayName": "Link"
21+
},
22+
"options": {},
23+
"attributes": {
24+
"Text": {
25+
"type": "string"
26+
"required": true,
27+
},
28+
"Link": {
29+
"type": "customField",
30+
"required": true,
31+
"customField": "plugin::webtools-addon-links.link"
32+
}
33+
}
34+
}
35+
```

0 commit comments

Comments
 (0)