mirror of
https://github.com/lancedikson/bowser
synced 2024-10-27 20:34:22 +00:00
refactor(bowser): replace static properties with getters
This commit is contained in:
parent
94530f010e
commit
41b66d5450
@ -51,11 +51,22 @@ class Bowser {
|
|||||||
static parse(UA) {
|
static parse(UA) {
|
||||||
return (new Parser(UA)).getResult();
|
return (new Parser(UA)).getResult();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static get BROWSER_MAP() {
|
||||||
|
return BROWSER_MAP;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bowser.BROWSER_MAP = BROWSER_MAP;
|
static get ENGINE_MAP() {
|
||||||
Bowser.ENGINE_MAP = ENGINE_MAP;
|
return ENGINE_MAP;
|
||||||
Bowser.OS_MAP = OS_MAP;
|
}
|
||||||
Bowser.PLATFORMS_MAP = PLATFORMS_MAP;
|
|
||||||
|
static get OS_MAP() {
|
||||||
|
return OS_MAP;
|
||||||
|
}
|
||||||
|
|
||||||
|
static get PLATFORMS_MAP() {
|
||||||
|
return PLATFORMS_MAP;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
export default Bowser;
|
export default Bowser;
|
||||||
|
Loading…
Reference in New Issue
Block a user