strapi-to-typescript icon indicating copy to clipboard operation
strapi-to-typescript copied to clipboard

component with the same name not created

Open haegemonia76 opened this issue 4 years ago • 1 comments

I have two components who do have the same name but not in the same category. Unfortunately, none of them are created, thus replaced by "any" inside my dynamiczone interface.

Is it possible to tackle this with one of the functions available in the stsconfig or is that currently impossible?

// .stsconfig
module.exports = {
  input: [
    './api',
    './node_modules/strapi-plugin-users-permissions',
    './node_modules/strapi-plugin-upload',
    './node_modules/strapi-plugin-i18n',
  ],
  components: './Strapi/components',
  output: './sts/',
  enum: true,
  nested: false,
  fieldType: (fieldType, fieldName) => {
    if (fieldName === 'id') return number;
    if (fieldType === 'datetime' || fieldType === 'date') return string;
  }
}

haegemonia76 avatar Oct 23 '21 10:10 haegemonia76

Hello, sorry but i no longer actively use Strapi. If you find a bug please follow this instruction or, better, create a pull request to fix it and I will integrate it asap .

aperron avatar Nov 19 '21 11:11 aperron