UNPKG

490 BJavaScriptView Raw
1/**
2 * pet
3 */
4export const CREATE_PET = "CREATE_PET";
5export const GET_PET = "GET_PET";
6export const LIST_PETS = "LIST_PETS";
7
8/**
9 * github
10 */
11export const LIST_REPOS = "LIST_REPOS";
12
13/**
14 * user
15 */
16export const LOGIN = "LOGIN";
17export const LOGOUT = "LOGOUT";
18
19// Add success and failure for string prototype
20Object.assign(String.prototype, {
21 success() {
22 return `${this}_SUCCESS`;
23 },
24 failure() {
25 return `${this}_FAILURE`;
26 },
27 glob() {
28 return `${this}_*`;
29 },
30});