const rules = {
url: 'includes:adonisjs.com'
}
// or
const rules = {
url: [
rule('includes', ['adonisjs.com'])
]
}
Ensures the value of field under validation contains a given substring.
const rules = {
url: 'includes:adonisjs.com'
}
// or
const rules = {
url: [
rule('includes', ['adonisjs.com'])
]
}
For customized build, you can import this rule as follows.
import { includes } from 'indicative/builds/validations'