5 changed files with 43 additions and 21 deletions
@ -1,7 +1,13 @@ |
|||||
{ |
{ |
||||
"hosting": { |
"hosting": { |
||||
"public": "dist", |
"public": "dist", |
||||
"rewrites": [{ "source": "/api/**", "function": "api" }], |
"rewrites": [ |
||||
|
{ "source": "/api/**", "function": "api" }, |
||||
|
{ |
||||
|
"source": "**", |
||||
|
"destination": "/index.html" |
||||
|
} |
||||
|
], |
||||
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"] |
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"] |
||||
} |
} |
||||
} |
} |
||||
|
|||||
@ -1,17 +1,33 @@ |
|||||
import api from 'mock/api'; |
import api from '../mock/api'; |
||||
import chart from 'mock/chart'; |
import chart from '../mock/chart'; |
||||
import geographic from 'mock/geographic'; |
import geographic from '../mock/geographic'; |
||||
import notices from 'mock/notices'; |
import notices from '../mock/notices'; |
||||
import profile from 'mock/profile'; |
import profile from '../mock/profile'; |
||||
import rule from 'mock/rule'; |
import rule from '../mock/rule'; |
||||
import user from 'mock/user'; |
import user from '../mock/user'; |
||||
|
|
||||
export default { |
const data = {}; |
||||
...api, |
Object.keys(api).forEach(key => { |
||||
...chart, |
data[key] = api[key]; |
||||
...geographic, |
}); |
||||
...notices, |
Object.keys(chart).forEach(key => { |
||||
...profile, |
data[key] = chart[key]; |
||||
...rule, |
}); |
||||
...user, |
|
||||
}; |
Object.keys(geographic).forEach(key => { |
||||
|
data[key] = geographic[key]; |
||||
|
}); |
||||
|
Object.keys(notices).forEach(key => { |
||||
|
data[key] = notices[key]; |
||||
|
}); |
||||
|
Object.keys(profile).forEach(key => { |
||||
|
data[key] = profile[key]; |
||||
|
}); |
||||
|
Object.keys(rule).forEach(key => { |
||||
|
data[key] = rule[key]; |
||||
|
}); |
||||
|
Object.keys(user).forEach(key => { |
||||
|
data[key] = user[key]; |
||||
|
}); |
||||
|
|
||||
|
export default data; |
||||
|
|||||
Loading…
Reference in new issue