Hi Emmanuel, You can do `type: ["String", "Regexp"]` to indicate multiple types that a field can accept.
On Thu, Aug 13, 2015 at 10:08 AM Emmanuel DEMEY <[email protected]> wrote: > Hi all > > I am currently working on the migration of my plugin eslint-plugin-angular > for ESLint 1.1.0. > > I have a quick question about the Schema, we must define for our rule, in > order to have a validation of the options before the execution of the rule. > > In my plugin, I have a rule that can have one parameter. the type of this > parameter can be String OR Regexp. > > Do you know how to define that a parameter can hav two different types ? > > I have checked the external module you use for the validation, but did not > find any information. > > Thanks > > Manu > @EmmanuelDemey > > -- > Emmanuel DEMEY > Consultant > Zenika > +33 (0)6 47 47 42 02 > [email protected] > > - fr.linkedin.com/in/emmanueldemey/ > > > Twitter : @EmmanuelDemey > > -- > You received this message because you are subscribed to the Google Groups > "ESLint" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "ESLint" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
