
Research
/Security News
npm Author Qix Compromised via Phishing Email in Major Supply Chain Attack
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.
@art-design-digital/payload-plugin-seo
Advanced tools
A Payload plugin for SEO. This plugin adds SEO fields to your collections and documents. It also provides a helper function to generate meta tags for your site.
This plugin implements some important SEO features for PayloadCMS.
It adds desired collections and globals fields that can be filled to provide various SEO metadata. It also supports editors in maintaining SEO data by requiring some fields as mandatory data and generating previews for the search results.
This field automatically generates a preview of how this page may appear in search results from the data provided. It has an option to switch between mobile and desktop previews. So the editor can see how the result looks for both breakpoints.
The plugin is an official npm library that can be installed via
npm install @art-design-digital/payload-plugin-seo
or via
yarn add @art-design-digital/payload-plugin-seo
The plugin is a plugin for PayloadCMS and so it can be installed by adding it to the plugins array in the payload.config.ts
The plugin works by adding no parameters (even no empty object) but it is disabled in using it this way. You have to set at least the props object with the enabled
property to enable it.
plugins: [
seoPlugin({
enabled: true
})
]
Here is the list of all available parameters that can be set in the plugin.
Name | Description | Type | Default |
---|---|---|---|
enabled | Switches the whole plugin on or off. | boolean | false |
collections | Array of slugs that defines in which collections the plugin shall be used. | string[] | [] |
globals | Array of slugs that defines in which globals the plugin shall be used. | string[] | [] |
mediaCollection | Tell the plugin which collection shall be used for uploading a photo for a team member. | string | 'media' |
generateSEOTitleFrom | Define the field from which the SEO-Title shall be generated from when clicking on Save . | string | '' |
insertBefore | Define on which position the field should be rendered in a specific global or collection. If nothing is set here the fields are appended. | {collections: [{slug: string, field: string}], globals: [{slug: string, field: string}]} | {} |
In this example you can see a full working configuration for a demo project.
seoPlugin({
enabled: true,
collections: ['examples', 'some-collection'],
globals: ['demo-global'],
mediaCollection: 'media',
generateSEOTitleFrom: 'someField',
insertBefore: {
globals: [
{
slug: 'demo-global',
field: 'description',
},
],
collections: [
{
slug: 'examples',
field: 'anotherField',
},
{
slug: 'some-collection',
field: 'niceField',
},
],
},
})
Please contact art&design digital with any questions about using this plugin.
FAQs
A Payload plugin for SEO. This plugin adds SEO fields to your collections and documents. It also provides a helper function to generate meta tags for your site.
The npm package @art-design-digital/payload-plugin-seo receives a total of 2 weekly downloads. As such, @art-design-digital/payload-plugin-seo popularity was classified as not popular.
We found that @art-design-digital/payload-plugin-seo demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
/Security News
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.