mirror of
https://github.com/iptv-org/database.git
synced 2025-05-10 19:50:01 -04:00
Replace require() with import
This commit is contained in:
parent
67cc28a408
commit
ea14a63978
16 changed files with 93 additions and 74 deletions
18
scripts/schemes/countries.ts
Normal file
18
scripts/schemes/countries.ts
Normal file
|
@ -0,0 +1,18 @@
|
|||
import Joi from 'joi'
|
||||
|
||||
export default {
|
||||
name: Joi.string()
|
||||
.regex(/^[\sA-Z\u00C0-\u00FF().-]+$/i)
|
||||
.required(),
|
||||
code: Joi.string()
|
||||
.regex(/^[A-Z]{2}$/)
|
||||
.required(),
|
||||
languages: Joi.array().items(
|
||||
Joi.string()
|
||||
.regex(/^[a-z]{3}$/)
|
||||
.required()
|
||||
),
|
||||
flag: Joi.string()
|
||||
.regex(/^[\uD83C][\uDDE6-\uDDFF][\uD83C][\uDDE6-\uDDFF]$/)
|
||||
.required()
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue