Register map custom field on the server

This commit is contained in:
Mark Kaylor 2022-08-11 16:16:24 +02:00
parent 74c3352761
commit ceb580e753

View File

@ -3,9 +3,16 @@
module.exports = ({ strapi }) => {
console.log('Running register in customfields plugin');
strapi.customFields.register({
name: 'color',
plugin: 'mycustomfields',
type: 'text',
});
strapi.customFields.register([
{
name: 'color',
plugin: 'mycustomfields',
type: 'text',
},
{
name: 'map',
plugin: 'mycustomfields',
type: 'json',
},
]);
};