1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
export const asType = (type, name) => [type, name].join('_').toUpperCase()
export const tagAsType = (type, names) => (
names.reduce((tags, name) => {
tags[name] = asType(type, name)
return tags
}, {})
)
export const faceAnalysis = tagAsType('faceAnalysis', [
'loading', 'loaded', 'poll', 'error', 'update_options',
])
export const faceSearch = tagAsType('faceSearch', [
'loading', 'loaded', 'error', 'update_options',
])
export const nameSearch = tagAsType('nameSearch', [
'loading', 'loaded', 'error', 'update_options',
])
export const init = '@@INIT'
|