🚀 Socket Launch Week 🚀 Day 5: Introducing Socket Fix.Learn More

payload-cms-text-array

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

payload-cms-text-array

I did not find a field that supports an array of strings in the documentation of Payload CMS so I made it myself.

0.1.1
latest
Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created

PayloadCMSTextArray

While working with payload CMS I did not find a field that could handle an array of strings. This was the inspiration to create this field myself and publish it so others could use it as well.

This package is a W.I.P.

To use this package import it and use it in a field like this:

import { TextArrayField, TextArrayCell } from 'payload-cms-text-array';

const Users: CollectionConfig = {
    slug: 'users',
    fields: [
        ...,
        {
            name: 'skills',
            type: 'text',
            admin: {
				components: {
					Field: TextArrayField,
					Cell: TextArrayCell
				}
			},
        }
    ]
}

Info

The component uses some custom classes and some classes from the dependency itself.

FAQs

Package last updated on 31 Aug 2023

Did you know?

Socket

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.

Install

Related posts