diff --git a/ghpages/docs/ast/source/config/configMgr.js.json b/ghpages/docs/ast/source/config/configMgr.js.json
index 8bdd2d6..a230cc1 100644
--- a/ghpages/docs/ast/source/config/configMgr.js.json
+++ b/ghpages/docs/ast/source/config/configMgr.js.json
@@ -1,7 +1,7 @@
{
"type": "File",
"start": 0,
- "end": 1320,
+ "end": 1317,
"loc": {
"start": {
"line": 1,
@@ -15,7 +15,7 @@
"program": {
"type": "Program",
"start": 0,
- "end": 1320,
+ "end": 1317,
"loc": {
"start": {
"line": 1,
@@ -2341,7 +2341,7 @@
{
"type": "Identifier",
"start": 966,
- "end": 1266,
+ "end": 1263,
"loc": {
"start": {
"line": 52,
@@ -2394,7 +2394,7 @@
"body": {
"type": "BlockStatement",
"start": 1000,
- "end": 1266,
+ "end": 1263,
"loc": {
"start": {
"line": 52,
@@ -2409,7 +2409,7 @@
{
"type": "IfStatement",
"start": 1005,
- "end": 1203,
+ "end": 1200,
"loc": {
"start": {
"line": 54,
@@ -2421,9 +2421,9 @@
}
},
"test": {
- "type": "UnaryExpression",
+ "type": "CallExpression",
"start": 1009,
- "end": 1034,
+ "end": 1031,
"loc": {
"start": {
"line": 54,
@@ -2431,29 +2431,44 @@
},
"end": {
"line": 54,
- "column": 31
+ "column": 28
}
},
- "operator": "!",
- "prefix": true,
- "argument": {
- "type": "CallExpression",
- "start": 1011,
- "end": 1033,
+ "callee": {
+ "type": "MemberExpression",
+ "start": 1009,
+ "end": 1014,
"loc": {
"start": {
"line": 54,
- "column": 8
+ "column": 6
},
"end": {
"line": 54,
- "column": 30
+ "column": 11
}
},
- "callee": {
- "type": "MemberExpression",
+ "object": {
+ "type": "Identifier",
+ "start": 1009,
+ "end": 1010,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 6
+ },
+ "end": {
+ "line": 54,
+ "column": 7
+ },
+ "identifierName": "_"
+ },
+ "name": "_"
+ },
+ "property": {
+ "type": "Identifier",
"start": 1011,
- "end": 1016,
+ "end": 1014,
"loc": {
"start": {
"line": 54,
@@ -2461,101 +2476,62 @@
},
"end": {
"line": 54,
- "column": 13
- }
- },
- "object": {
- "type": "Identifier",
- "start": 1011,
- "end": 1012,
- "loc": {
- "start": {
- "line": 54,
- "column": 8
- },
- "end": {
- "line": 54,
- "column": 9
- },
- "identifierName": "_"
+ "column": 11
},
- "name": "_"
+ "identifierName": "has"
},
- "property": {
- "type": "Identifier",
- "start": 1013,
- "end": 1016,
- "loc": {
- "start": {
- "line": 54,
- "column": 10
- },
- "end": {
- "line": 54,
- "column": 13
- },
- "identifierName": "has"
+ "name": "has"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 1015,
+ "end": 1025,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 12
},
- "name": "has"
+ "end": {
+ "line": 54,
+ "column": 22
+ },
+ "identifierName": "userConfig"
},
- "computed": false
+ "name": "userConfig"
},
- "arguments": [
- {
- "type": "Identifier",
- "start": 1017,
- "end": 1027,
- "loc": {
- "start": {
- "line": 54,
- "column": 14
- },
- "end": {
- "line": 54,
- "column": 24
- },
- "identifierName": "userConfig"
+ {
+ "type": "StringLiteral",
+ "start": 1027,
+ "end": 1030,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 24
},
- "name": "userConfig"
+ "end": {
+ "line": 54,
+ "column": 27
+ }
},
- {
- "type": "StringLiteral",
- "start": 1029,
- "end": 1032,
- "loc": {
- "start": {
- "line": 54,
- "column": 26
- },
- "end": {
- "line": 54,
- "column": 29
- }
- },
- "extra": {
- "rawValue": "_",
- "raw": "'_'"
- },
- "value": "_"
- }
- ],
- "extra": {
- "parenthesized": true,
- "parenStart": 1010
+ "extra": {
+ "rawValue": "_",
+ "raw": "'_'"
+ },
+ "value": "_"
}
- },
- "extra": {
- "parenthesizedArgument": false
- }
+ ]
},
"consequent": {
"type": "BlockStatement",
- "start": 1035,
- "end": 1203,
+ "start": 1032,
+ "end": 1200,
"loc": {
"start": {
"line": 54,
- "column": 32
+ "column": 29
},
"end": {
"line": 60,
@@ -2565,8 +2541,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1041,
- "end": 1199,
+ "start": 1038,
+ "end": 1196,
"loc": {
"start": {
"line": 55,
@@ -2579,8 +2555,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1041,
- "end": 1198,
+ "start": 1038,
+ "end": 1195,
"loc": {
"start": {
"line": 55,
@@ -2593,8 +2569,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1041,
- "end": 1156,
+ "start": 1038,
+ "end": 1153,
"loc": {
"start": {
"line": 55,
@@ -2607,8 +2583,8 @@
},
"object": {
"type": "CallExpression",
- "start": 1041,
- "end": 1150,
+ "start": 1038,
+ "end": 1147,
"loc": {
"start": {
"line": 55,
@@ -2621,8 +2597,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1041,
- "end": 1099,
+ "start": 1038,
+ "end": 1096,
"loc": {
"start": {
"line": 55,
@@ -2635,8 +2611,8 @@
},
"object": {
"type": "CallExpression",
- "start": 1041,
- "end": 1094,
+ "start": 1038,
+ "end": 1091,
"loc": {
"start": {
"line": 55,
@@ -2649,8 +2625,8 @@
},
"callee": {
"type": "Import",
- "start": 1041,
- "end": 1047,
+ "start": 1038,
+ "end": 1044,
"loc": {
"start": {
"line": 55,
@@ -2665,8 +2641,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 1074,
- "end": 1093,
+ "start": 1071,
+ "end": 1090,
"loc": {
"start": {
"line": 55,
@@ -2686,8 +2662,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 1048,
- "end": 1073,
+ "start": 1045,
+ "end": 1070,
"loc": {
"start": {
"line": 55,
@@ -2705,8 +2681,8 @@
},
"property": {
"type": "Identifier",
- "start": 1095,
- "end": 1099,
+ "start": 1092,
+ "end": 1096,
"loc": {
"start": {
"line": 55,
@@ -2725,8 +2701,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 1100,
- "end": 1149,
+ "start": 1097,
+ "end": 1146,
"loc": {
"start": {
"line": 55,
@@ -2744,8 +2720,8 @@
"params": [
{
"type": "Identifier",
- "start": 1100,
- "end": 1101,
+ "start": 1097,
+ "end": 1098,
"loc": {
"start": {
"line": 55,
@@ -2762,8 +2738,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 1105,
- "end": 1149,
+ "start": 1102,
+ "end": 1146,
"loc": {
"start": {
"line": 55,
@@ -2777,8 +2753,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1113,
- "end": 1143,
+ "start": 1110,
+ "end": 1140,
"loc": {
"start": {
"line": 56,
@@ -2791,8 +2767,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1113,
- "end": 1142,
+ "start": 1110,
+ "end": 1139,
"loc": {
"start": {
"line": 56,
@@ -2805,8 +2781,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1113,
- "end": 1130,
+ "start": 1110,
+ "end": 1127,
"loc": {
"start": {
"line": 56,
@@ -2819,8 +2795,8 @@
},
"object": {
"type": "Identifier",
- "start": 1113,
- "end": 1114,
+ "start": 1110,
+ "end": 1111,
"loc": {
"start": {
"line": 56,
@@ -2836,8 +2812,8 @@
},
"property": {
"type": "Identifier",
- "start": 1115,
- "end": 1130,
+ "start": 1112,
+ "end": 1127,
"loc": {
"start": {
"line": 56,
@@ -2856,8 +2832,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1131,
- "end": 1141,
+ "start": 1128,
+ "end": 1138,
"loc": {
"start": {
"line": 56,
@@ -2882,8 +2858,8 @@
},
"property": {
"type": "Identifier",
- "start": 1151,
- "end": 1156,
+ "start": 1148,
+ "end": 1153,
"loc": {
"start": {
"line": 57,
@@ -2902,8 +2878,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 1157,
- "end": 1197,
+ "start": 1154,
+ "end": 1194,
"loc": {
"start": {
"line": 57,
@@ -2921,8 +2897,8 @@
"params": [
{
"type": "Identifier",
- "start": 1157,
- "end": 1160,
+ "start": 1154,
+ "end": 1157,
"loc": {
"start": {
"line": 57,
@@ -2939,8 +2915,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 1164,
- "end": 1197,
+ "start": 1161,
+ "end": 1194,
"loc": {
"start": {
"line": 57,
@@ -2954,8 +2930,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1172,
- "end": 1191,
+ "start": 1169,
+ "end": 1188,
"loc": {
"start": {
"line": 58,
@@ -2968,8 +2944,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1172,
- "end": 1190,
+ "start": 1169,
+ "end": 1187,
"loc": {
"start": {
"line": 58,
@@ -2982,8 +2958,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1172,
- "end": 1185,
+ "start": 1169,
+ "end": 1182,
"loc": {
"start": {
"line": 58,
@@ -2996,8 +2972,8 @@
},
"object": {
"type": "Identifier",
- "start": 1172,
- "end": 1179,
+ "start": 1169,
+ "end": 1176,
"loc": {
"start": {
"line": 58,
@@ -3013,8 +2989,8 @@
},
"property": {
"type": "Identifier",
- "start": 1180,
- "end": 1185,
+ "start": 1177,
+ "end": 1182,
"loc": {
"start": {
"line": 58,
@@ -3033,8 +3009,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1186,
- "end": 1189,
+ "start": 1183,
+ "end": 1186,
"loc": {
"start": {
"line": 58,
@@ -3065,8 +3041,8 @@
},
{
"type": "ExpressionStatement",
- "start": 1207,
- "end": 1263,
+ "start": 1204,
+ "end": 1260,
"loc": {
"start": {
"line": 62,
@@ -3079,8 +3055,8 @@
},
"expression": {
"type": "AssignmentExpression",
- "start": 1207,
- "end": 1262,
+ "start": 1204,
+ "end": 1259,
"loc": {
"start": {
"line": 62,
@@ -3094,8 +3070,8 @@
"operator": "=",
"left": {
"type": "Identifier",
- "start": 1207,
- "end": 1217,
+ "start": 1204,
+ "end": 1214,
"loc": {
"start": {
"line": 62,
@@ -3111,8 +3087,8 @@
},
"right": {
"type": "CallExpression",
- "start": 1220,
- "end": 1262,
+ "start": 1217,
+ "end": 1259,
"loc": {
"start": {
"line": 62,
@@ -3125,8 +3101,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1220,
- "end": 1234,
+ "start": 1217,
+ "end": 1231,
"loc": {
"start": {
"line": 62,
@@ -3139,8 +3115,8 @@
},
"object": {
"type": "Identifier",
- "start": 1220,
- "end": 1221,
+ "start": 1217,
+ "end": 1218,
"loc": {
"start": {
"line": 62,
@@ -3156,8 +3132,8 @@
},
"property": {
"type": "Identifier",
- "start": 1222,
- "end": 1234,
+ "start": 1219,
+ "end": 1231,
"loc": {
"start": {
"line": 62,
@@ -3176,8 +3152,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1235,
- "end": 1245,
+ "start": 1232,
+ "end": 1242,
"loc": {
"start": {
"line": 62,
@@ -3193,8 +3169,8 @@
},
{
"type": "Identifier",
- "start": 1247,
- "end": 1261,
+ "start": 1244,
+ "end": 1258,
"loc": {
"start": {
"line": 62,
@@ -3221,8 +3197,8 @@
},
{
"type": "ExportNamedDeclaration",
- "start": 1268,
- "end": 1319,
+ "start": 1265,
+ "end": 1316,
"loc": {
"start": {
"line": 66,
@@ -3237,8 +3213,8 @@
"specifiers": [
{
"type": "ExportSpecifier",
- "start": 1279,
- "end": 1292,
+ "start": 1276,
+ "end": 1289,
"loc": {
"start": {
"line": 67,
@@ -3251,8 +3227,8 @@
},
"local": {
"type": "Identifier",
- "start": 1279,
- "end": 1292,
+ "start": 1276,
+ "end": 1289,
"loc": {
"start": {
"line": 67,
@@ -3268,8 +3244,8 @@
},
"exported": {
"type": "Identifier",
- "start": 1279,
- "end": 1292,
+ "start": 1276,
+ "end": 1289,
"loc": {
"start": {
"line": 67,
@@ -3286,8 +3262,8 @@
},
{
"type": "ExportSpecifier",
- "start": 1296,
- "end": 1316,
+ "start": 1293,
+ "end": 1313,
"loc": {
"start": {
"line": 68,
@@ -3300,8 +3276,8 @@
},
"local": {
"type": "Identifier",
- "start": 1296,
- "end": 1306,
+ "start": 1293,
+ "end": 1303,
"loc": {
"start": {
"line": 68,
@@ -3317,8 +3293,8 @@
},
"exported": {
"type": "Identifier",
- "start": 1310,
- "end": 1316,
+ "start": 1307,
+ "end": 1313,
"loc": {
"start": {
"line": 68,
@@ -3338,8 +3314,8 @@
},
{
"type": "ExportNamedDeclaration",
- "start": 1268,
- "end": 1319,
+ "start": 1265,
+ "end": 1316,
"loc": {
"start": {
"line": 66,
@@ -3353,7 +3329,7 @@
"declaration": {
"type": "FunctionDeclaration",
"start": 966,
- "end": 1266,
+ "end": 1263,
"loc": {
"start": {
"line": 52,
@@ -3406,7 +3382,7 @@
"body": {
"type": "BlockStatement",
"start": 1000,
- "end": 1266,
+ "end": 1263,
"loc": {
"start": {
"line": 52,
@@ -3421,7 +3397,7 @@
{
"type": "IfStatement",
"start": 1005,
- "end": 1203,
+ "end": 1200,
"loc": {
"start": {
"line": 54,
@@ -3433,9 +3409,9 @@
}
},
"test": {
- "type": "UnaryExpression",
+ "type": "CallExpression",
"start": 1009,
- "end": 1034,
+ "end": 1031,
"loc": {
"start": {
"line": 54,
@@ -3443,29 +3419,44 @@
},
"end": {
"line": 54,
- "column": 31
+ "column": 28
}
},
- "operator": "!",
- "prefix": true,
- "argument": {
- "type": "CallExpression",
- "start": 1011,
- "end": 1033,
+ "callee": {
+ "type": "MemberExpression",
+ "start": 1009,
+ "end": 1014,
"loc": {
"start": {
"line": 54,
- "column": 8
+ "column": 6
},
"end": {
"line": 54,
- "column": 30
+ "column": 11
}
},
- "callee": {
- "type": "MemberExpression",
+ "object": {
+ "type": "Identifier",
+ "start": 1009,
+ "end": 1010,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 6
+ },
+ "end": {
+ "line": 54,
+ "column": 7
+ },
+ "identifierName": "_"
+ },
+ "name": "_"
+ },
+ "property": {
+ "type": "Identifier",
"start": 1011,
- "end": 1016,
+ "end": 1014,
"loc": {
"start": {
"line": 54,
@@ -3473,101 +3464,62 @@
},
"end": {
"line": 54,
- "column": 13
- }
- },
- "object": {
- "type": "Identifier",
- "start": 1011,
- "end": 1012,
- "loc": {
- "start": {
- "line": 54,
- "column": 8
- },
- "end": {
- "line": 54,
- "column": 9
- },
- "identifierName": "_"
+ "column": 11
},
- "name": "_"
+ "identifierName": "has"
},
- "property": {
- "type": "Identifier",
- "start": 1013,
- "end": 1016,
- "loc": {
- "start": {
- "line": 54,
- "column": 10
- },
- "end": {
- "line": 54,
- "column": 13
- },
- "identifierName": "has"
+ "name": "has"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 1015,
+ "end": 1025,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 12
+ },
+ "end": {
+ "line": 54,
+ "column": 22
},
- "name": "has"
+ "identifierName": "userConfig"
},
- "computed": false
+ "name": "userConfig"
},
- "arguments": [
- {
- "type": "Identifier",
- "start": 1017,
- "end": 1027,
- "loc": {
- "start": {
- "line": 54,
- "column": 14
- },
- "end": {
- "line": 54,
- "column": 24
- },
- "identifierName": "userConfig"
+ {
+ "type": "StringLiteral",
+ "start": 1027,
+ "end": 1030,
+ "loc": {
+ "start": {
+ "line": 54,
+ "column": 24
},
- "name": "userConfig"
+ "end": {
+ "line": 54,
+ "column": 27
+ }
},
- {
- "type": "StringLiteral",
- "start": 1029,
- "end": 1032,
- "loc": {
- "start": {
- "line": 54,
- "column": 26
- },
- "end": {
- "line": 54,
- "column": 29
- }
- },
- "extra": {
- "rawValue": "_",
- "raw": "'_'"
- },
- "value": "_"
- }
- ],
- "extra": {
- "parenthesized": true,
- "parenStart": 1010
+ "extra": {
+ "rawValue": "_",
+ "raw": "'_'"
+ },
+ "value": "_"
}
- },
- "extra": {
- "parenthesizedArgument": false
- }
+ ]
},
"consequent": {
"type": "BlockStatement",
- "start": 1035,
- "end": 1203,
+ "start": 1032,
+ "end": 1200,
"loc": {
"start": {
"line": 54,
- "column": 32
+ "column": 29
},
"end": {
"line": 60,
@@ -3577,8 +3529,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1041,
- "end": 1199,
+ "start": 1038,
+ "end": 1196,
"loc": {
"start": {
"line": 55,
@@ -3591,8 +3543,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1041,
- "end": 1198,
+ "start": 1038,
+ "end": 1195,
"loc": {
"start": {
"line": 55,
@@ -3605,8 +3557,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1041,
- "end": 1156,
+ "start": 1038,
+ "end": 1153,
"loc": {
"start": {
"line": 55,
@@ -3619,8 +3571,8 @@
},
"object": {
"type": "CallExpression",
- "start": 1041,
- "end": 1150,
+ "start": 1038,
+ "end": 1147,
"loc": {
"start": {
"line": 55,
@@ -3633,8 +3585,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1041,
- "end": 1099,
+ "start": 1038,
+ "end": 1096,
"loc": {
"start": {
"line": 55,
@@ -3647,8 +3599,8 @@
},
"object": {
"type": "CallExpression",
- "start": 1041,
- "end": 1094,
+ "start": 1038,
+ "end": 1091,
"loc": {
"start": {
"line": 55,
@@ -3661,8 +3613,8 @@
},
"callee": {
"type": "Import",
- "start": 1041,
- "end": 1047,
+ "start": 1038,
+ "end": 1044,
"loc": {
"start": {
"line": 55,
@@ -3677,8 +3629,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 1074,
- "end": 1093,
+ "start": 1071,
+ "end": 1090,
"loc": {
"start": {
"line": 55,
@@ -3698,8 +3650,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 1048,
- "end": 1073,
+ "start": 1045,
+ "end": 1070,
"loc": {
"start": {
"line": 55,
@@ -3717,8 +3669,8 @@
},
"property": {
"type": "Identifier",
- "start": 1095,
- "end": 1099,
+ "start": 1092,
+ "end": 1096,
"loc": {
"start": {
"line": 55,
@@ -3737,8 +3689,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 1100,
- "end": 1149,
+ "start": 1097,
+ "end": 1146,
"loc": {
"start": {
"line": 55,
@@ -3756,8 +3708,8 @@
"params": [
{
"type": "Identifier",
- "start": 1100,
- "end": 1101,
+ "start": 1097,
+ "end": 1098,
"loc": {
"start": {
"line": 55,
@@ -3774,8 +3726,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 1105,
- "end": 1149,
+ "start": 1102,
+ "end": 1146,
"loc": {
"start": {
"line": 55,
@@ -3789,8 +3741,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1113,
- "end": 1143,
+ "start": 1110,
+ "end": 1140,
"loc": {
"start": {
"line": 56,
@@ -3803,8 +3755,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1113,
- "end": 1142,
+ "start": 1110,
+ "end": 1139,
"loc": {
"start": {
"line": 56,
@@ -3817,8 +3769,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1113,
- "end": 1130,
+ "start": 1110,
+ "end": 1127,
"loc": {
"start": {
"line": 56,
@@ -3831,8 +3783,8 @@
},
"object": {
"type": "Identifier",
- "start": 1113,
- "end": 1114,
+ "start": 1110,
+ "end": 1111,
"loc": {
"start": {
"line": 56,
@@ -3848,8 +3800,8 @@
},
"property": {
"type": "Identifier",
- "start": 1115,
- "end": 1130,
+ "start": 1112,
+ "end": 1127,
"loc": {
"start": {
"line": 56,
@@ -3868,8 +3820,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1131,
- "end": 1141,
+ "start": 1128,
+ "end": 1138,
"loc": {
"start": {
"line": 56,
@@ -3894,8 +3846,8 @@
},
"property": {
"type": "Identifier",
- "start": 1151,
- "end": 1156,
+ "start": 1148,
+ "end": 1153,
"loc": {
"start": {
"line": 57,
@@ -3914,8 +3866,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 1157,
- "end": 1197,
+ "start": 1154,
+ "end": 1194,
"loc": {
"start": {
"line": 57,
@@ -3933,8 +3885,8 @@
"params": [
{
"type": "Identifier",
- "start": 1157,
- "end": 1160,
+ "start": 1154,
+ "end": 1157,
"loc": {
"start": {
"line": 57,
@@ -3951,8 +3903,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 1164,
- "end": 1197,
+ "start": 1161,
+ "end": 1194,
"loc": {
"start": {
"line": 57,
@@ -3966,8 +3918,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 1172,
- "end": 1191,
+ "start": 1169,
+ "end": 1188,
"loc": {
"start": {
"line": 58,
@@ -3980,8 +3932,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 1172,
- "end": 1190,
+ "start": 1169,
+ "end": 1187,
"loc": {
"start": {
"line": 58,
@@ -3994,8 +3946,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1172,
- "end": 1185,
+ "start": 1169,
+ "end": 1182,
"loc": {
"start": {
"line": 58,
@@ -4008,8 +3960,8 @@
},
"object": {
"type": "Identifier",
- "start": 1172,
- "end": 1179,
+ "start": 1169,
+ "end": 1176,
"loc": {
"start": {
"line": 58,
@@ -4025,8 +3977,8 @@
},
"property": {
"type": "Identifier",
- "start": 1180,
- "end": 1185,
+ "start": 1177,
+ "end": 1182,
"loc": {
"start": {
"line": 58,
@@ -4045,8 +3997,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1186,
- "end": 1189,
+ "start": 1183,
+ "end": 1186,
"loc": {
"start": {
"line": 58,
@@ -4077,8 +4029,8 @@
},
{
"type": "ExpressionStatement",
- "start": 1207,
- "end": 1263,
+ "start": 1204,
+ "end": 1260,
"loc": {
"start": {
"line": 62,
@@ -4091,8 +4043,8 @@
},
"expression": {
"type": "AssignmentExpression",
- "start": 1207,
- "end": 1262,
+ "start": 1204,
+ "end": 1259,
"loc": {
"start": {
"line": 62,
@@ -4106,8 +4058,8 @@
"operator": "=",
"left": {
"type": "Identifier",
- "start": 1207,
- "end": 1217,
+ "start": 1204,
+ "end": 1214,
"loc": {
"start": {
"line": 62,
@@ -4123,8 +4075,8 @@
},
"right": {
"type": "CallExpression",
- "start": 1220,
- "end": 1262,
+ "start": 1217,
+ "end": 1259,
"loc": {
"start": {
"line": 62,
@@ -4137,8 +4089,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 1220,
- "end": 1234,
+ "start": 1217,
+ "end": 1231,
"loc": {
"start": {
"line": 62,
@@ -4151,8 +4103,8 @@
},
"object": {
"type": "Identifier",
- "start": 1220,
- "end": 1221,
+ "start": 1217,
+ "end": 1218,
"loc": {
"start": {
"line": 62,
@@ -4168,8 +4120,8 @@
},
"property": {
"type": "Identifier",
- "start": 1222,
- "end": 1234,
+ "start": 1219,
+ "end": 1231,
"loc": {
"start": {
"line": 62,
@@ -4188,8 +4140,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 1235,
- "end": 1245,
+ "start": 1232,
+ "end": 1242,
"loc": {
"start": {
"line": 62,
@@ -4205,8 +4157,8 @@
},
{
"type": "Identifier",
- "start": 1247,
- "end": 1261,
+ "start": 1244,
+ "end": 1258,
"loc": {
"start": {
"line": 62,
@@ -4472,8 +4424,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 1048,
- "end": 1073,
+ "start": 1045,
+ "end": 1070,
"loc": {
"start": {
"line": 55,
@@ -9486,58 +9438,6 @@
}
}
},
- {
- "type": {
- "label": "prefix",
- "beforeExpr": true,
- "startsExpr": true,
- "rightAssociative": false,
- "isLoop": false,
- "isAssign": false,
- "prefix": true,
- "postfix": false,
- "binop": null,
- "updateContext": null
- },
- "value": "!",
- "start": 1009,
- "end": 1010,
- "loc": {
- "start": {
- "line": 54,
- "column": 6
- },
- "end": {
- "line": 54,
- "column": 7
- }
- }
- },
- {
- "type": {
- "label": "(",
- "beforeExpr": true,
- "startsExpr": true,
- "rightAssociative": false,
- "isLoop": false,
- "isAssign": false,
- "prefix": false,
- "postfix": false,
- "binop": null
- },
- "start": 1010,
- "end": 1011,
- "loc": {
- "start": {
- "line": 54,
- "column": 7
- },
- "end": {
- "line": 54,
- "column": 8
- }
- }
- },
{
"type": {
"label": "name",
@@ -9551,16 +9451,16 @@
"binop": null
},
"value": "_",
- "start": 1011,
- "end": 1012,
+ "start": 1009,
+ "end": 1010,
"loc": {
"start": {
"line": 54,
- "column": 8
+ "column": 6
},
"end": {
"line": 54,
- "column": 9
+ "column": 7
}
}
},
@@ -9577,16 +9477,16 @@
"binop": null,
"updateContext": null
},
- "start": 1012,
- "end": 1013,
+ "start": 1010,
+ "end": 1011,
"loc": {
"start": {
"line": 54,
- "column": 9
+ "column": 7
},
"end": {
"line": 54,
- "column": 10
+ "column": 8
}
}
},
@@ -9603,16 +9503,16 @@
"binop": null
},
"value": "has",
- "start": 1013,
- "end": 1016,
+ "start": 1011,
+ "end": 1014,
"loc": {
"start": {
"line": 54,
- "column": 10
+ "column": 8
},
"end": {
"line": 54,
- "column": 13
+ "column": 11
}
}
},
@@ -9628,16 +9528,16 @@
"postfix": false,
"binop": null
},
- "start": 1016,
- "end": 1017,
+ "start": 1014,
+ "end": 1015,
"loc": {
"start": {
"line": 54,
- "column": 13
+ "column": 11
},
"end": {
"line": 54,
- "column": 14
+ "column": 12
}
}
},
@@ -9654,16 +9554,16 @@
"binop": null
},
"value": "userConfig",
- "start": 1017,
- "end": 1027,
+ "start": 1015,
+ "end": 1025,
"loc": {
"start": {
"line": 54,
- "column": 14
+ "column": 12
},
"end": {
"line": 54,
- "column": 24
+ "column": 22
}
}
},
@@ -9680,16 +9580,16 @@
"binop": null,
"updateContext": null
},
- "start": 1027,
- "end": 1028,
+ "start": 1025,
+ "end": 1026,
"loc": {
"start": {
"line": 54,
- "column": 24
+ "column": 22
},
"end": {
"line": 54,
- "column": 25
+ "column": 23
}
}
},
@@ -9707,41 +9607,16 @@
"updateContext": null
},
"value": "_",
- "start": 1029,
- "end": 1032,
- "loc": {
- "start": {
- "line": 54,
- "column": 26
- },
- "end": {
- "line": 54,
- "column": 29
- }
- }
- },
- {
- "type": {
- "label": ")",
- "beforeExpr": false,
- "startsExpr": false,
- "rightAssociative": false,
- "isLoop": false,
- "isAssign": false,
- "prefix": false,
- "postfix": false,
- "binop": null
- },
- "start": 1032,
- "end": 1033,
+ "start": 1027,
+ "end": 1030,
"loc": {
"start": {
"line": 54,
- "column": 29
+ "column": 24
},
"end": {
"line": 54,
- "column": 30
+ "column": 27
}
}
},
@@ -9757,16 +9632,16 @@
"postfix": false,
"binop": null
},
- "start": 1033,
- "end": 1034,
+ "start": 1030,
+ "end": 1031,
"loc": {
"start": {
"line": 54,
- "column": 30
+ "column": 27
},
"end": {
"line": 54,
- "column": 31
+ "column": 28
}
}
},
@@ -9782,16 +9657,16 @@
"postfix": false,
"binop": null
},
- "start": 1034,
- "end": 1035,
+ "start": 1031,
+ "end": 1032,
"loc": {
"start": {
"line": 54,
- "column": 31
+ "column": 28
},
"end": {
"line": 54,
- "column": 32
+ "column": 29
}
}
},
@@ -9807,16 +9682,16 @@
"postfix": false,
"binop": null
},
- "start": 1035,
- "end": 1036,
+ "start": 1032,
+ "end": 1033,
"loc": {
"start": {
"line": 54,
- "column": 32
+ "column": 29
},
"end": {
"line": 54,
- "column": 33
+ "column": 30
}
}
},
@@ -9835,8 +9710,8 @@
"updateContext": null
},
"value": "import",
- "start": 1041,
- "end": 1047,
+ "start": 1038,
+ "end": 1044,
"loc": {
"start": {
"line": 55,
@@ -9860,8 +9735,8 @@
"postfix": false,
"binop": null
},
- "start": 1047,
- "end": 1048,
+ "start": 1044,
+ "end": 1045,
"loc": {
"start": {
"line": 55,
@@ -9876,8 +9751,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 1048,
- "end": 1073,
+ "start": 1045,
+ "end": 1070,
"loc": {
"start": {
"line": 55,
@@ -9903,8 +9778,8 @@
"updateContext": null
},
"value": "./configValidater",
- "start": 1074,
- "end": 1093,
+ "start": 1071,
+ "end": 1090,
"loc": {
"start": {
"line": 55,
@@ -9928,8 +9803,8 @@
"postfix": false,
"binop": null
},
- "start": 1093,
- "end": 1094,
+ "start": 1090,
+ "end": 1091,
"loc": {
"start": {
"line": 55,
@@ -9954,8 +9829,8 @@
"binop": null,
"updateContext": null
},
- "start": 1094,
- "end": 1095,
+ "start": 1091,
+ "end": 1092,
"loc": {
"start": {
"line": 55,
@@ -9980,8 +9855,8 @@
"binop": null
},
"value": "then",
- "start": 1095,
- "end": 1099,
+ "start": 1092,
+ "end": 1096,
"loc": {
"start": {
"line": 55,
@@ -10005,8 +9880,8 @@
"postfix": false,
"binop": null
},
- "start": 1099,
- "end": 1100,
+ "start": 1096,
+ "end": 1097,
"loc": {
"start": {
"line": 55,
@@ -10031,8 +9906,8 @@
"binop": null
},
"value": "f",
- "start": 1100,
- "end": 1101,
+ "start": 1097,
+ "end": 1098,
"loc": {
"start": {
"line": 55,
@@ -10057,8 +9932,8 @@
"binop": null,
"updateContext": null
},
- "start": 1102,
- "end": 1104,
+ "start": 1099,
+ "end": 1101,
"loc": {
"start": {
"line": 55,
@@ -10082,8 +9957,8 @@
"postfix": false,
"binop": null
},
- "start": 1105,
- "end": 1106,
+ "start": 1102,
+ "end": 1103,
"loc": {
"start": {
"line": 55,
@@ -10108,8 +9983,8 @@
"binop": null
},
"value": "f",
- "start": 1113,
- "end": 1114,
+ "start": 1110,
+ "end": 1111,
"loc": {
"start": {
"line": 56,
@@ -10134,8 +10009,8 @@
"binop": null,
"updateContext": null
},
- "start": 1114,
- "end": 1115,
+ "start": 1111,
+ "end": 1112,
"loc": {
"start": {
"line": 56,
@@ -10160,8 +10035,8 @@
"binop": null
},
"value": "configValidater",
- "start": 1115,
- "end": 1130,
+ "start": 1112,
+ "end": 1127,
"loc": {
"start": {
"line": 56,
@@ -10185,8 +10060,8 @@
"postfix": false,
"binop": null
},
- "start": 1130,
- "end": 1131,
+ "start": 1127,
+ "end": 1128,
"loc": {
"start": {
"line": 56,
@@ -10211,8 +10086,8 @@
"binop": null
},
"value": "userConfig",
- "start": 1131,
- "end": 1141,
+ "start": 1128,
+ "end": 1138,
"loc": {
"start": {
"line": 56,
@@ -10236,8 +10111,8 @@
"postfix": false,
"binop": null
},
- "start": 1141,
- "end": 1142,
+ "start": 1138,
+ "end": 1139,
"loc": {
"start": {
"line": 56,
@@ -10262,8 +10137,8 @@
"binop": null,
"updateContext": null
},
- "start": 1142,
- "end": 1143,
+ "start": 1139,
+ "end": 1140,
"loc": {
"start": {
"line": 56,
@@ -10287,8 +10162,8 @@
"postfix": false,
"binop": null
},
- "start": 1148,
- "end": 1149,
+ "start": 1145,
+ "end": 1146,
"loc": {
"start": {
"line": 57,
@@ -10312,8 +10187,8 @@
"postfix": false,
"binop": null
},
- "start": 1149,
- "end": 1150,
+ "start": 1146,
+ "end": 1147,
"loc": {
"start": {
"line": 57,
@@ -10338,8 +10213,8 @@
"binop": null,
"updateContext": null
},
- "start": 1150,
- "end": 1151,
+ "start": 1147,
+ "end": 1148,
"loc": {
"start": {
"line": 57,
@@ -10366,8 +10241,8 @@
"updateContext": null
},
"value": "catch",
- "start": 1151,
- "end": 1156,
+ "start": 1148,
+ "end": 1153,
"loc": {
"start": {
"line": 57,
@@ -10391,8 +10266,8 @@
"postfix": false,
"binop": null
},
- "start": 1156,
- "end": 1157,
+ "start": 1153,
+ "end": 1154,
"loc": {
"start": {
"line": 57,
@@ -10417,8 +10292,8 @@
"binop": null
},
"value": "err",
- "start": 1157,
- "end": 1160,
+ "start": 1154,
+ "end": 1157,
"loc": {
"start": {
"line": 57,
@@ -10443,8 +10318,8 @@
"binop": null,
"updateContext": null
},
- "start": 1161,
- "end": 1163,
+ "start": 1158,
+ "end": 1160,
"loc": {
"start": {
"line": 57,
@@ -10468,8 +10343,8 @@
"postfix": false,
"binop": null
},
- "start": 1164,
- "end": 1165,
+ "start": 1161,
+ "end": 1162,
"loc": {
"start": {
"line": 57,
@@ -10494,8 +10369,8 @@
"binop": null
},
"value": "console",
- "start": 1172,
- "end": 1179,
+ "start": 1169,
+ "end": 1176,
"loc": {
"start": {
"line": 58,
@@ -10520,8 +10395,8 @@
"binop": null,
"updateContext": null
},
- "start": 1179,
- "end": 1180,
+ "start": 1176,
+ "end": 1177,
"loc": {
"start": {
"line": 58,
@@ -10546,8 +10421,8 @@
"binop": null
},
"value": "error",
- "start": 1180,
- "end": 1185,
+ "start": 1177,
+ "end": 1182,
"loc": {
"start": {
"line": 58,
@@ -10571,8 +10446,8 @@
"postfix": false,
"binop": null
},
- "start": 1185,
- "end": 1186,
+ "start": 1182,
+ "end": 1183,
"loc": {
"start": {
"line": 58,
@@ -10597,8 +10472,8 @@
"binop": null
},
"value": "err",
- "start": 1186,
- "end": 1189,
+ "start": 1183,
+ "end": 1186,
"loc": {
"start": {
"line": 58,
@@ -10622,8 +10497,8 @@
"postfix": false,
"binop": null
},
- "start": 1189,
- "end": 1190,
+ "start": 1186,
+ "end": 1187,
"loc": {
"start": {
"line": 58,
@@ -10648,8 +10523,8 @@
"binop": null,
"updateContext": null
},
- "start": 1190,
- "end": 1191,
+ "start": 1187,
+ "end": 1188,
"loc": {
"start": {
"line": 58,
@@ -10673,8 +10548,8 @@
"postfix": false,
"binop": null
},
- "start": 1196,
- "end": 1197,
+ "start": 1193,
+ "end": 1194,
"loc": {
"start": {
"line": 59,
@@ -10698,8 +10573,8 @@
"postfix": false,
"binop": null
},
- "start": 1197,
- "end": 1198,
+ "start": 1194,
+ "end": 1195,
"loc": {
"start": {
"line": 59,
@@ -10724,8 +10599,8 @@
"binop": null,
"updateContext": null
},
- "start": 1198,
- "end": 1199,
+ "start": 1195,
+ "end": 1196,
"loc": {
"start": {
"line": 59,
@@ -10749,8 +10624,8 @@
"postfix": false,
"binop": null
},
- "start": 1202,
- "end": 1203,
+ "start": 1199,
+ "end": 1200,
"loc": {
"start": {
"line": 60,
@@ -10775,8 +10650,8 @@
"binop": null
},
"value": "currConfig",
- "start": 1207,
- "end": 1217,
+ "start": 1204,
+ "end": 1214,
"loc": {
"start": {
"line": 62,
@@ -10802,8 +10677,8 @@
"updateContext": null
},
"value": "=",
- "start": 1218,
- "end": 1219,
+ "start": 1215,
+ "end": 1216,
"loc": {
"start": {
"line": 62,
@@ -10828,8 +10703,8 @@
"binop": null
},
"value": "_",
- "start": 1220,
- "end": 1221,
+ "start": 1217,
+ "end": 1218,
"loc": {
"start": {
"line": 62,
@@ -10854,8 +10729,8 @@
"binop": null,
"updateContext": null
},
- "start": 1221,
- "end": 1222,
+ "start": 1218,
+ "end": 1219,
"loc": {
"start": {
"line": 62,
@@ -10880,8 +10755,8 @@
"binop": null
},
"value": "defaultsDeep",
- "start": 1222,
- "end": 1234,
+ "start": 1219,
+ "end": 1231,
"loc": {
"start": {
"line": 62,
@@ -10905,8 +10780,8 @@
"postfix": false,
"binop": null
},
- "start": 1234,
- "end": 1235,
+ "start": 1231,
+ "end": 1232,
"loc": {
"start": {
"line": 62,
@@ -10931,8 +10806,8 @@
"binop": null
},
"value": "userConfig",
- "start": 1235,
- "end": 1245,
+ "start": 1232,
+ "end": 1242,
"loc": {
"start": {
"line": 62,
@@ -10957,8 +10832,8 @@
"binop": null,
"updateContext": null
},
- "start": 1245,
- "end": 1246,
+ "start": 1242,
+ "end": 1243,
"loc": {
"start": {
"line": 62,
@@ -10983,8 +10858,8 @@
"binop": null
},
"value": "defaultOptions",
- "start": 1247,
- "end": 1261,
+ "start": 1244,
+ "end": 1258,
"loc": {
"start": {
"line": 62,
@@ -11008,8 +10883,8 @@
"postfix": false,
"binop": null
},
- "start": 1261,
- "end": 1262,
+ "start": 1258,
+ "end": 1259,
"loc": {
"start": {
"line": 62,
@@ -11034,8 +10909,8 @@
"binop": null,
"updateContext": null
},
- "start": 1262,
- "end": 1263,
+ "start": 1259,
+ "end": 1260,
"loc": {
"start": {
"line": 62,
@@ -11059,8 +10934,8 @@
"postfix": false,
"binop": null
},
- "start": 1265,
- "end": 1266,
+ "start": 1262,
+ "end": 1263,
"loc": {
"start": {
"line": 64,
@@ -11087,8 +10962,8 @@
"updateContext": null
},
"value": "export",
- "start": 1268,
- "end": 1274,
+ "start": 1265,
+ "end": 1271,
"loc": {
"start": {
"line": 66,
@@ -11112,8 +10987,8 @@
"postfix": false,
"binop": null
},
- "start": 1275,
- "end": 1276,
+ "start": 1272,
+ "end": 1273,
"loc": {
"start": {
"line": 66,
@@ -11138,8 +11013,8 @@
"binop": null
},
"value": "configApplyer",
- "start": 1279,
- "end": 1292,
+ "start": 1276,
+ "end": 1289,
"loc": {
"start": {
"line": 67,
@@ -11164,8 +11039,8 @@
"binop": null,
"updateContext": null
},
- "start": 1292,
- "end": 1293,
+ "start": 1289,
+ "end": 1290,
"loc": {
"start": {
"line": 67,
@@ -11190,8 +11065,8 @@
"binop": null
},
"value": "currConfig",
- "start": 1296,
- "end": 1306,
+ "start": 1293,
+ "end": 1303,
"loc": {
"start": {
"line": 68,
@@ -11216,8 +11091,8 @@
"binop": null
},
"value": "as",
- "start": 1307,
- "end": 1309,
+ "start": 1304,
+ "end": 1306,
"loc": {
"start": {
"line": 68,
@@ -11242,8 +11117,8 @@
"binop": null
},
"value": "config",
- "start": 1310,
- "end": 1316,
+ "start": 1307,
+ "end": 1313,
"loc": {
"start": {
"line": 68,
@@ -11268,8 +11143,8 @@
"binop": null,
"updateContext": null
},
- "start": 1316,
- "end": 1317,
+ "start": 1313,
+ "end": 1314,
"loc": {
"start": {
"line": 68,
@@ -11293,8 +11168,8 @@
"postfix": false,
"binop": null
},
- "start": 1318,
- "end": 1319,
+ "start": 1315,
+ "end": 1316,
"loc": {
"start": {
"line": 69,
@@ -11319,8 +11194,8 @@
"binop": null,
"updateContext": null
},
- "start": 1320,
- "end": 1320,
+ "start": 1317,
+ "end": 1317,
"loc": {
"start": {
"line": 70,
diff --git a/ghpages/docs/ast/source/index.js.json b/ghpages/docs/ast/source/index.js.json
index b669b15..5ff029c 100644
--- a/ghpages/docs/ast/source/index.js.json
+++ b/ghpages/docs/ast/source/index.js.json
@@ -1,28 +1,28 @@
{
"type": "File",
"start": 0,
- "end": 919,
+ "end": 932,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
- "line": 45,
+ "line": 49,
"column": 0
}
},
"program": {
"type": "Program",
"start": 0,
- "end": 919,
+ "end": 932,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
- "line": 45,
+ "line": 49,
"column": 0
}
},
@@ -250,30 +250,1584 @@
}
]
},
+ {
+ "type": "Identifier",
+ "start": 387,
+ "end": 911,
+ "loc": {
+ "start": {
+ "line": 22,
+ "column": 0
+ },
+ "end": {
+ "line": 44,
+ "column": 1
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 396,
+ "end": 400,
+ "loc": {
+ "start": {
+ "line": 22,
+ "column": 9
+ },
+ "end": {
+ "line": 22,
+ "column": 13
+ },
+ "identifierName": "init"
+ },
+ "name": "init",
+ "leadingComments": null
+ },
+ "generator": false,
+ "expression": false,
+ "async": false,
+ "params": [
+ {
+ "type": "Identifier",
+ "start": 401,
+ "end": 411,
+ "loc": {
+ "start": {
+ "line": 22,
+ "column": 14
+ },
+ "end": {
+ "line": 22,
+ "column": 24
+ },
+ "identifierName": "userConfig"
+ },
+ "name": "userConfig"
+ }
+ ],
+ "body": {
+ "type": "BlockStatement",
+ "start": 412,
+ "end": 911,
+ "loc": {
+ "start": {
+ "line": 22,
+ "column": 25
+ },
+ "end": {
+ "line": 44,
+ "column": 1
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 417,
+ "end": 482,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 2
+ },
+ "end": {
+ "line": 24,
+ "column": 67
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 417,
+ "end": 481,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 2
+ },
+ "end": {
+ "line": 24,
+ "column": 66
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 417,
+ "end": 427,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 2
+ },
+ "end": {
+ "line": 24,
+ "column": 12
+ },
+ "identifierName": "userConfig"
+ },
+ "name": "userConfig"
+ },
+ "right": {
+ "type": "ConditionalExpression",
+ "start": 430,
+ "end": 481,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 15
+ },
+ "end": {
+ "line": 24,
+ "column": 66
+ }
+ },
+ "test": {
+ "type": "BinaryExpression",
+ "start": 430,
+ "end": 463,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 15
+ },
+ "end": {
+ "line": 24,
+ "column": 48
+ }
+ },
+ "left": {
+ "type": "UnaryExpression",
+ "start": 430,
+ "end": 447,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 15
+ },
+ "end": {
+ "line": 24,
+ "column": 32
+ }
+ },
+ "operator": "typeof",
+ "prefix": true,
+ "argument": {
+ "type": "Identifier",
+ "start": 437,
+ "end": 447,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 22
+ },
+ "end": {
+ "line": 24,
+ "column": 32
+ },
+ "identifierName": "userConfig"
+ },
+ "name": "userConfig"
+ },
+ "extra": {
+ "parenthesizedArgument": false
+ }
+ },
+ "operator": "===",
+ "right": {
+ "type": "StringLiteral",
+ "start": 452,
+ "end": 463,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 37
+ },
+ "end": {
+ "line": 24,
+ "column": 48
+ }
+ },
+ "extra": {
+ "rawValue": "undefined",
+ "raw": "'undefined'"
+ },
+ "value": "undefined"
+ }
+ },
+ "consequent": {
+ "type": "ObjectExpression",
+ "start": 466,
+ "end": 468,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 51
+ },
+ "end": {
+ "line": 24,
+ "column": 53
+ }
+ },
+ "properties": []
+ },
+ "alternate": {
+ "type": "Identifier",
+ "start": 471,
+ "end": 481,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 56
+ },
+ "end": {
+ "line": 24,
+ "column": 66
+ },
+ "identifierName": "userConfig"
+ },
+ "name": "userConfig"
+ }
+ }
+ }
+ },
+ {
+ "type": "IfStatement",
+ "start": 486,
+ "end": 681,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 2
+ },
+ "end": {
+ "line": 30,
+ "column": 3
+ }
+ },
+ "test": {
+ "type": "BinaryExpression",
+ "start": 490,
+ "end": 528,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 6
+ },
+ "end": {
+ "line": 26,
+ "column": 44
+ }
+ },
+ "left": {
+ "type": "MemberExpression",
+ "start": 490,
+ "end": 510,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 6
+ },
+ "end": {
+ "line": 26,
+ "column": 26
+ }
+ },
+ "object": {
+ "type": "MemberExpression",
+ "start": 490,
+ "end": 501,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 6
+ },
+ "end": {
+ "line": 26,
+ "column": 17
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 490,
+ "end": 497,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 6
+ },
+ "end": {
+ "line": 26,
+ "column": 13
+ },
+ "identifierName": "process"
+ },
+ "name": "process"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 498,
+ "end": 501,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 14
+ },
+ "end": {
+ "line": 26,
+ "column": 17
+ },
+ "identifierName": "env"
+ },
+ "name": "env"
+ },
+ "computed": false
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 502,
+ "end": 510,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 18
+ },
+ "end": {
+ "line": 26,
+ "column": 26
+ },
+ "identifierName": "NODE_ENV"
+ },
+ "name": "NODE_ENV"
+ },
+ "computed": false
+ },
+ "operator": "===",
+ "right": {
+ "type": "StringLiteral",
+ "start": 515,
+ "end": 528,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 31
+ },
+ "end": {
+ "line": 26,
+ "column": 44
+ }
+ },
+ "extra": {
+ "rawValue": "development",
+ "raw": "'development'"
+ },
+ "value": "development"
+ }
+ },
+ "consequent": {
+ "type": "BlockStatement",
+ "start": 529,
+ "end": 681,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 45
+ },
+ "end": {
+ "line": 30,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 535,
+ "end": 570,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 4
+ },
+ "end": {
+ "line": 27,
+ "column": 39
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 535,
+ "end": 569,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 4
+ },
+ "end": {
+ "line": 27,
+ "column": 38
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 535,
+ "end": 546,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 4
+ },
+ "end": {
+ "line": 27,
+ "column": 15
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 535,
+ "end": 542,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 4
+ },
+ "end": {
+ "line": 27,
+ "column": 11
+ },
+ "identifierName": "console"
+ },
+ "name": "console"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 543,
+ "end": 546,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 12
+ },
+ "end": {
+ "line": 27,
+ "column": 15
+ },
+ "identifierName": "log"
+ },
+ "name": "log"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "StringLiteral",
+ "start": 547,
+ "end": 568,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 16
+ },
+ "end": {
+ "line": 27,
+ "column": 37
+ }
+ },
+ "extra": {
+ "rawValue": "--- --- --- --- ---",
+ "raw": "'--- --- --- --- ---'"
+ },
+ "value": "--- --- --- --- ---"
+ }
+ ]
+ }
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 575,
+ "end": 637,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 66
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 575,
+ "end": 636,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 65
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 575,
+ "end": 586,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 15
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 575,
+ "end": 582,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 11
+ },
+ "identifierName": "console"
+ },
+ "name": "console"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 583,
+ "end": 586,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 12
+ },
+ "end": {
+ "line": 28,
+ "column": 15
+ },
+ "identifierName": "log"
+ },
+ "name": "log"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "StringLiteral",
+ "start": 587,
+ "end": 635,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 16
+ },
+ "end": {
+ "line": 28,
+ "column": 64
+ }
+ },
+ "extra": {
+ "rawValue": "Hey that, notice that you are now in DEV MODE.",
+ "raw": "'Hey that, notice that you are now in DEV MODE.'"
+ },
+ "value": "Hey that, notice that you are now in DEV MODE."
+ }
+ ]
+ }
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 642,
+ "end": 677,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 4
+ },
+ "end": {
+ "line": 29,
+ "column": 39
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 642,
+ "end": 676,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 4
+ },
+ "end": {
+ "line": 29,
+ "column": 38
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 642,
+ "end": 653,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 4
+ },
+ "end": {
+ "line": 29,
+ "column": 15
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 642,
+ "end": 649,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 4
+ },
+ "end": {
+ "line": 29,
+ "column": 11
+ },
+ "identifierName": "console"
+ },
+ "name": "console"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 650,
+ "end": 653,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 12
+ },
+ "end": {
+ "line": 29,
+ "column": 15
+ },
+ "identifierName": "log"
+ },
+ "name": "log"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "StringLiteral",
+ "start": 654,
+ "end": 675,
+ "loc": {
+ "start": {
+ "line": 29,
+ "column": 16
+ },
+ "end": {
+ "line": 29,
+ "column": 37
+ }
+ },
+ "extra": {
+ "rawValue": "--- --- --- --- ---",
+ "raw": "'--- --- --- --- ---'"
+ },
+ "value": "--- --- --- --- ---"
+ }
+ ]
+ }
+ }
+ ],
+ "directives": []
+ },
+ "alternate": null
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 685,
+ "end": 711,
+ "loc": {
+ "start": {
+ "line": 32,
+ "column": 2
+ },
+ "end": {
+ "line": 32,
+ "column": 28
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 685,
+ "end": 710,
+ "loc": {
+ "start": {
+ "line": 32,
+ "column": 2
+ },
+ "end": {
+ "line": 32,
+ "column": 27
+ }
+ },
+ "callee": {
+ "type": "Identifier",
+ "start": 685,
+ "end": 698,
+ "loc": {
+ "start": {
+ "line": 32,
+ "column": 2
+ },
+ "end": {
+ "line": 32,
+ "column": 15
+ },
+ "identifierName": "configApplyer"
+ },
+ "name": "configApplyer"
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 699,
+ "end": 709,
+ "loc": {
+ "start": {
+ "line": 32,
+ "column": 16
+ },
+ "end": {
+ "line": 32,
+ "column": 26
+ },
+ "identifierName": "userConfig"
+ },
+ "name": "userConfig"
+ }
+ ]
+ }
+ },
+ {
+ "type": "IfStatement",
+ "start": 715,
+ "end": 776,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 2
+ },
+ "end": {
+ "line": 36,
+ "column": 3
+ }
+ },
+ "test": {
+ "type": "LogicalExpression",
+ "start": 718,
+ "end": 758,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 5
+ },
+ "end": {
+ "line": 34,
+ "column": 45
+ }
+ },
+ "left": {
+ "type": "UnaryExpression",
+ "start": 719,
+ "end": 738,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 6
+ },
+ "end": {
+ "line": 34,
+ "column": 25
+ }
+ },
+ "operator": "!",
+ "prefix": true,
+ "argument": {
+ "type": "MemberExpression",
+ "start": 720,
+ "end": 738,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 7
+ },
+ "end": {
+ "line": 34,
+ "column": 25
+ }
+ },
+ "object": {
+ "type": "MemberExpression",
+ "start": 720,
+ "end": 733,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 7
+ },
+ "end": {
+ "line": 34,
+ "column": 20
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 720,
+ "end": 726,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 7
+ },
+ "end": {
+ "line": 34,
+ "column": 13
+ },
+ "identifierName": "config"
+ },
+ "name": "config"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 727,
+ "end": 733,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 14
+ },
+ "end": {
+ "line": 34,
+ "column": 20
+ },
+ "identifierName": "mobile"
+ },
+ "name": "mobile"
+ },
+ "computed": false
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 734,
+ "end": 738,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 21
+ },
+ "end": {
+ "line": 34,
+ "column": 25
+ },
+ "identifierName": "show"
+ },
+ "name": "show"
+ },
+ "computed": false
+ },
+ "extra": {
+ "parenthesizedArgument": false,
+ "parenthesized": true,
+ "parenStart": 718
+ }
+ },
+ "operator": "&&",
+ "right": {
+ "type": "CallExpression",
+ "start": 742,
+ "end": 757,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 29
+ },
+ "end": {
+ "line": 34,
+ "column": 44
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 742,
+ "end": 755,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 29
+ },
+ "end": {
+ "line": 34,
+ "column": 42
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 742,
+ "end": 748,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 29
+ },
+ "end": {
+ "line": 34,
+ "column": 35
+ },
+ "identifierName": "device"
+ },
+ "name": "device"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 749,
+ "end": 755,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 36
+ },
+ "end": {
+ "line": 34,
+ "column": 42
+ },
+ "identifierName": "mobile"
+ },
+ "name": "mobile"
+ },
+ "computed": false
+ },
+ "arguments": [],
+ "extra": {
+ "parenthesized": true,
+ "parenStart": 741
+ }
+ }
+ },
+ "consequent": {
+ "type": "BlockStatement",
+ "start": 759,
+ "end": 776,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 46
+ },
+ "end": {
+ "line": 36,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "ReturnStatement",
+ "start": 765,
+ "end": 772,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 11
+ }
+ },
+ "argument": null
+ }
+ ],
+ "directives": []
+ },
+ "alternate": null
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 780,
+ "end": 908,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 42,
+ "column": 5
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 780,
+ "end": 907,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 42,
+ "column": 4
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 780,
+ "end": 869,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 40,
+ "column": 10
+ }
+ },
+ "object": {
+ "type": "CallExpression",
+ "start": 780,
+ "end": 863,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 40,
+ "column": 4
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 780,
+ "end": 834,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 38,
+ "column": 56
+ }
+ },
+ "object": {
+ "type": "CallExpression",
+ "start": 780,
+ "end": 829,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 38,
+ "column": 51
+ }
+ },
+ "callee": {
+ "type": "Import",
+ "start": 780,
+ "end": 786,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 2
+ },
+ "end": {
+ "line": 38,
+ "column": 8
+ }
+ }
+ },
+ "arguments": [
+ {
+ "type": "StringLiteral",
+ "start": 813,
+ "end": 828,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 35
+ },
+ "end": {
+ "line": 38,
+ "column": 50
+ }
+ },
+ "extra": {
+ "rawValue": "./_cLive2DApp",
+ "raw": "'./_cLive2DApp'"
+ },
+ "value": "./_cLive2DApp",
+ "leadingComments": [
+ {
+ "type": "CommentBlock",
+ "value": " webpackMode: \"lazy\" ",
+ "start": 787,
+ "end": 812,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 9
+ },
+ "end": {
+ "line": 38,
+ "column": 34
+ }
+ }
+ }
+ ]
+ }
+ ]
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 830,
+ "end": 834,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 52
+ },
+ "end": {
+ "line": 38,
+ "column": 56
+ },
+ "identifierName": "then"
+ },
+ "name": "then"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "ArrowFunctionExpression",
+ "start": 835,
+ "end": 862,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 57
+ },
+ "end": {
+ "line": 40,
+ "column": 3
+ }
+ },
+ "id": null,
+ "generator": false,
+ "expression": false,
+ "async": false,
+ "params": [
+ {
+ "type": "Identifier",
+ "start": 835,
+ "end": 836,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 57
+ },
+ "end": {
+ "line": 38,
+ "column": 58
+ },
+ "identifierName": "f"
+ },
+ "name": "f"
+ }
+ ],
+ "body": {
+ "type": "BlockStatement",
+ "start": 840,
+ "end": 862,
+ "loc": {
+ "start": {
+ "line": 38,
+ "column": 62
+ },
+ "end": {
+ "line": 40,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 846,
+ "end": 858,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 4
+ },
+ "end": {
+ "line": 39,
+ "column": 16
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 846,
+ "end": 857,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 4
+ },
+ "end": {
+ "line": 39,
+ "column": 15
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 846,
+ "end": 855,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 4
+ },
+ "end": {
+ "line": 39,
+ "column": 13
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 846,
+ "end": 847,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 4
+ },
+ "end": {
+ "line": 39,
+ "column": 5
+ },
+ "identifierName": "f"
+ },
+ "name": "f"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 848,
+ "end": 855,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 6
+ },
+ "end": {
+ "line": 39,
+ "column": 13
+ },
+ "identifierName": "default"
+ },
+ "name": "default"
+ },
+ "computed": false
+ },
+ "arguments": []
+ }
+ }
+ ],
+ "directives": []
+ }
+ }
+ ]
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 864,
+ "end": 869,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 5
+ },
+ "end": {
+ "line": 40,
+ "column": 10
+ },
+ "identifierName": "catch"
+ },
+ "name": "catch"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "ArrowFunctionExpression",
+ "start": 870,
+ "end": 906,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 11
+ },
+ "end": {
+ "line": 42,
+ "column": 3
+ }
+ },
+ "id": null,
+ "generator": false,
+ "expression": false,
+ "async": false,
+ "params": [
+ {
+ "type": "Identifier",
+ "start": 870,
+ "end": 873,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 11
+ },
+ "end": {
+ "line": 40,
+ "column": 14
+ },
+ "identifierName": "err"
+ },
+ "name": "err"
+ }
+ ],
+ "body": {
+ "type": "BlockStatement",
+ "start": 877,
+ "end": 906,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 18
+ },
+ "end": {
+ "line": 42,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 883,
+ "end": 902,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 4
+ },
+ "end": {
+ "line": 41,
+ "column": 23
+ }
+ },
+ "expression": {
+ "type": "CallExpression",
+ "start": 883,
+ "end": 901,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 4
+ },
+ "end": {
+ "line": 41,
+ "column": 22
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 883,
+ "end": 896,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 4
+ },
+ "end": {
+ "line": 41,
+ "column": 17
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 883,
+ "end": 890,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 4
+ },
+ "end": {
+ "line": 41,
+ "column": 11
+ },
+ "identifierName": "console"
+ },
+ "name": "console"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 891,
+ "end": 896,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 12
+ },
+ "end": {
+ "line": 41,
+ "column": 17
+ },
+ "identifierName": "error"
+ },
+ "name": "error"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 897,
+ "end": 900,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 18
+ },
+ "end": {
+ "line": 41,
+ "column": 21
+ },
+ "identifierName": "err"
+ },
+ "name": "err"
+ }
+ ]
+ }
+ }
+ ],
+ "directives": []
+ }
+ }
+ ]
+ }
+ }
+ ],
+ "directives": []
+ },
+ "leadingComments": [],
+ "name": "_",
+ "trailingComments": []
+ },
{
"type": "ExportNamedDeclaration",
- "start": 387,
- "end": 918,
+ "start": 913,
+ "end": 931,
"loc": {
"start": {
- "line": 22,
+ "line": 46,
"column": 0
},
"end": {
- "line": 44,
+ "line": 48,
+ "column": 1
+ }
+ },
+ "declaration": null,
+ "specifiers": [
+ {
+ "type": "ExportSpecifier",
+ "start": 924,
+ "end": 928,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 2
+ },
+ "end": {
+ "line": 47,
+ "column": 6
+ }
+ },
+ "local": {
+ "type": "Identifier",
+ "start": 924,
+ "end": 928,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 2
+ },
+ "end": {
+ "line": 47,
+ "column": 6
+ },
+ "identifierName": "init"
+ },
+ "name": "init"
+ },
+ "exported": {
+ "type": "Identifier",
+ "start": 924,
+ "end": 928,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 2
+ },
+ "end": {
+ "line": 47,
+ "column": 6
+ },
+ "identifierName": "init"
+ },
+ "name": "init"
+ }
+ }
+ ],
+ "source": null
+ },
+ {
+ "type": "ExportNamedDeclaration",
+ "start": 913,
+ "end": 931,
+ "loc": {
+ "start": {
+ "line": 46,
+ "column": 0
+ },
+ "end": {
+ "line": 48,
"column": 1
}
},
- "specifiers": [],
- "source": null,
"declaration": {
"type": "FunctionDeclaration",
- "start": 394,
- "end": 918,
+ "start": 387,
+ "end": 911,
"loc": {
"start": {
"line": 22,
- "column": 7
+ "column": 0
},
"end": {
"line": 44,
@@ -282,16 +1836,16 @@
},
"id": {
"type": "Identifier",
- "start": 403,
- "end": 407,
+ "start": 396,
+ "end": 400,
"loc": {
"start": {
"line": 22,
- "column": 16
+ "column": 9
},
"end": {
"line": 22,
- "column": 20
+ "column": 13
},
"identifierName": "init"
},
@@ -304,16 +1858,16 @@
"params": [
{
"type": "Identifier",
- "start": 408,
- "end": 418,
+ "start": 401,
+ "end": 411,
"loc": {
"start": {
"line": 22,
- "column": 21
+ "column": 14
},
"end": {
"line": 22,
- "column": 31
+ "column": 24
},
"identifierName": "userConfig"
},
@@ -322,12 +1876,12 @@
],
"body": {
"type": "BlockStatement",
- "start": 419,
- "end": 918,
+ "start": 412,
+ "end": 911,
"loc": {
"start": {
"line": 22,
- "column": 32
+ "column": 25
},
"end": {
"line": 44,
@@ -337,8 +1891,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 424,
- "end": 489,
+ "start": 417,
+ "end": 482,
"loc": {
"start": {
"line": 24,
@@ -351,8 +1905,8 @@
},
"expression": {
"type": "AssignmentExpression",
- "start": 424,
- "end": 488,
+ "start": 417,
+ "end": 481,
"loc": {
"start": {
"line": 24,
@@ -366,8 +1920,8 @@
"operator": "=",
"left": {
"type": "Identifier",
- "start": 424,
- "end": 434,
+ "start": 417,
+ "end": 427,
"loc": {
"start": {
"line": 24,
@@ -383,8 +1937,8 @@
},
"right": {
"type": "ConditionalExpression",
- "start": 437,
- "end": 488,
+ "start": 430,
+ "end": 481,
"loc": {
"start": {
"line": 24,
@@ -397,8 +1951,8 @@
},
"test": {
"type": "BinaryExpression",
- "start": 437,
- "end": 470,
+ "start": 430,
+ "end": 463,
"loc": {
"start": {
"line": 24,
@@ -411,8 +1965,8 @@
},
"left": {
"type": "UnaryExpression",
- "start": 437,
- "end": 454,
+ "start": 430,
+ "end": 447,
"loc": {
"start": {
"line": 24,
@@ -427,8 +1981,8 @@
"prefix": true,
"argument": {
"type": "Identifier",
- "start": 444,
- "end": 454,
+ "start": 437,
+ "end": 447,
"loc": {
"start": {
"line": 24,
@@ -449,8 +2003,8 @@
"operator": "===",
"right": {
"type": "StringLiteral",
- "start": 459,
- "end": 470,
+ "start": 452,
+ "end": 463,
"loc": {
"start": {
"line": 24,
@@ -470,8 +2024,8 @@
},
"consequent": {
"type": "ObjectExpression",
- "start": 473,
- "end": 475,
+ "start": 466,
+ "end": 468,
"loc": {
"start": {
"line": 24,
@@ -486,8 +2040,8 @@
},
"alternate": {
"type": "Identifier",
- "start": 478,
- "end": 488,
+ "start": 471,
+ "end": 481,
"loc": {
"start": {
"line": 24,
@@ -506,8 +2060,8 @@
},
{
"type": "IfStatement",
- "start": 493,
- "end": 688,
+ "start": 486,
+ "end": 681,
"loc": {
"start": {
"line": 26,
@@ -520,8 +2074,8 @@
},
"test": {
"type": "BinaryExpression",
- "start": 497,
- "end": 535,
+ "start": 490,
+ "end": 528,
"loc": {
"start": {
"line": 26,
@@ -534,8 +2088,8 @@
},
"left": {
"type": "MemberExpression",
- "start": 497,
- "end": 517,
+ "start": 490,
+ "end": 510,
"loc": {
"start": {
"line": 26,
@@ -548,8 +2102,8 @@
},
"object": {
"type": "MemberExpression",
- "start": 497,
- "end": 508,
+ "start": 490,
+ "end": 501,
"loc": {
"start": {
"line": 26,
@@ -562,8 +2116,8 @@
},
"object": {
"type": "Identifier",
- "start": 497,
- "end": 504,
+ "start": 490,
+ "end": 497,
"loc": {
"start": {
"line": 26,
@@ -579,8 +2133,8 @@
},
"property": {
"type": "Identifier",
- "start": 505,
- "end": 508,
+ "start": 498,
+ "end": 501,
"loc": {
"start": {
"line": 26,
@@ -598,8 +2152,8 @@
},
"property": {
"type": "Identifier",
- "start": 509,
- "end": 517,
+ "start": 502,
+ "end": 510,
"loc": {
"start": {
"line": 26,
@@ -618,8 +2172,8 @@
"operator": "===",
"right": {
"type": "StringLiteral",
- "start": 522,
- "end": 535,
+ "start": 515,
+ "end": 528,
"loc": {
"start": {
"line": 26,
@@ -639,8 +2193,8 @@
},
"consequent": {
"type": "BlockStatement",
- "start": 536,
- "end": 688,
+ "start": 529,
+ "end": 681,
"loc": {
"start": {
"line": 26,
@@ -654,8 +2208,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 542,
- "end": 577,
+ "start": 535,
+ "end": 570,
"loc": {
"start": {
"line": 27,
@@ -668,8 +2222,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 542,
- "end": 576,
+ "start": 535,
+ "end": 569,
"loc": {
"start": {
"line": 27,
@@ -682,8 +2236,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 542,
- "end": 553,
+ "start": 535,
+ "end": 546,
"loc": {
"start": {
"line": 27,
@@ -696,8 +2250,8 @@
},
"object": {
"type": "Identifier",
- "start": 542,
- "end": 549,
+ "start": 535,
+ "end": 542,
"loc": {
"start": {
"line": 27,
@@ -713,8 +2267,8 @@
},
"property": {
"type": "Identifier",
- "start": 550,
- "end": 553,
+ "start": 543,
+ "end": 546,
"loc": {
"start": {
"line": 27,
@@ -733,8 +2287,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 554,
- "end": 575,
+ "start": 547,
+ "end": 568,
"loc": {
"start": {
"line": 27,
@@ -756,8 +2310,8 @@
},
{
"type": "ExpressionStatement",
- "start": 582,
- "end": 644,
+ "start": 575,
+ "end": 637,
"loc": {
"start": {
"line": 28,
@@ -770,8 +2324,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 582,
- "end": 643,
+ "start": 575,
+ "end": 636,
"loc": {
"start": {
"line": 28,
@@ -784,8 +2338,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 582,
- "end": 593,
+ "start": 575,
+ "end": 586,
"loc": {
"start": {
"line": 28,
@@ -798,8 +2352,8 @@
},
"object": {
"type": "Identifier",
- "start": 582,
- "end": 589,
+ "start": 575,
+ "end": 582,
"loc": {
"start": {
"line": 28,
@@ -815,8 +2369,8 @@
},
"property": {
"type": "Identifier",
- "start": 590,
- "end": 593,
+ "start": 583,
+ "end": 586,
"loc": {
"start": {
"line": 28,
@@ -835,8 +2389,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 594,
- "end": 642,
+ "start": 587,
+ "end": 635,
"loc": {
"start": {
"line": 28,
@@ -858,8 +2412,8 @@
},
{
"type": "ExpressionStatement",
- "start": 649,
- "end": 684,
+ "start": 642,
+ "end": 677,
"loc": {
"start": {
"line": 29,
@@ -872,8 +2426,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 649,
- "end": 683,
+ "start": 642,
+ "end": 676,
"loc": {
"start": {
"line": 29,
@@ -886,8 +2440,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 649,
- "end": 660,
+ "start": 642,
+ "end": 653,
"loc": {
"start": {
"line": 29,
@@ -900,8 +2454,8 @@
},
"object": {
"type": "Identifier",
- "start": 649,
- "end": 656,
+ "start": 642,
+ "end": 649,
"loc": {
"start": {
"line": 29,
@@ -917,8 +2471,8 @@
},
"property": {
"type": "Identifier",
- "start": 657,
- "end": 660,
+ "start": 650,
+ "end": 653,
"loc": {
"start": {
"line": 29,
@@ -937,8 +2491,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 661,
- "end": 682,
+ "start": 654,
+ "end": 675,
"loc": {
"start": {
"line": 29,
@@ -965,8 +2519,8 @@
},
{
"type": "ExpressionStatement",
- "start": 692,
- "end": 718,
+ "start": 685,
+ "end": 711,
"loc": {
"start": {
"line": 32,
@@ -979,8 +2533,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 692,
- "end": 717,
+ "start": 685,
+ "end": 710,
"loc": {
"start": {
"line": 32,
@@ -993,8 +2547,8 @@
},
"callee": {
"type": "Identifier",
- "start": 692,
- "end": 705,
+ "start": 685,
+ "end": 698,
"loc": {
"start": {
"line": 32,
@@ -1011,8 +2565,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 706,
- "end": 716,
+ "start": 699,
+ "end": 709,
"loc": {
"start": {
"line": 32,
@@ -1031,8 +2585,8 @@
},
{
"type": "IfStatement",
- "start": 722,
- "end": 783,
+ "start": 715,
+ "end": 776,
"loc": {
"start": {
"line": 34,
@@ -1045,8 +2599,8 @@
},
"test": {
"type": "LogicalExpression",
- "start": 725,
- "end": 765,
+ "start": 718,
+ "end": 758,
"loc": {
"start": {
"line": 34,
@@ -1059,8 +2613,8 @@
},
"left": {
"type": "UnaryExpression",
- "start": 726,
- "end": 745,
+ "start": 719,
+ "end": 738,
"loc": {
"start": {
"line": 34,
@@ -1075,8 +2629,8 @@
"prefix": true,
"argument": {
"type": "MemberExpression",
- "start": 727,
- "end": 745,
+ "start": 720,
+ "end": 738,
"loc": {
"start": {
"line": 34,
@@ -1089,8 +2643,8 @@
},
"object": {
"type": "MemberExpression",
- "start": 727,
- "end": 740,
+ "start": 720,
+ "end": 733,
"loc": {
"start": {
"line": 34,
@@ -1103,8 +2657,8 @@
},
"object": {
"type": "Identifier",
- "start": 727,
- "end": 733,
+ "start": 720,
+ "end": 726,
"loc": {
"start": {
"line": 34,
@@ -1120,8 +2674,8 @@
},
"property": {
"type": "Identifier",
- "start": 734,
- "end": 740,
+ "start": 727,
+ "end": 733,
"loc": {
"start": {
"line": 34,
@@ -1139,8 +2693,8 @@
},
"property": {
"type": "Identifier",
- "start": 741,
- "end": 745,
+ "start": 734,
+ "end": 738,
"loc": {
"start": {
"line": 34,
@@ -1159,14 +2713,14 @@
"extra": {
"parenthesizedArgument": false,
"parenthesized": true,
- "parenStart": 725
+ "parenStart": 718
}
},
"operator": "&&",
"right": {
"type": "CallExpression",
- "start": 749,
- "end": 764,
+ "start": 742,
+ "end": 757,
"loc": {
"start": {
"line": 34,
@@ -1179,8 +2733,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 749,
- "end": 762,
+ "start": 742,
+ "end": 755,
"loc": {
"start": {
"line": 34,
@@ -1193,8 +2747,8 @@
},
"object": {
"type": "Identifier",
- "start": 749,
- "end": 755,
+ "start": 742,
+ "end": 748,
"loc": {
"start": {
"line": 34,
@@ -1210,8 +2764,8 @@
},
"property": {
"type": "Identifier",
- "start": 756,
- "end": 762,
+ "start": 749,
+ "end": 755,
"loc": {
"start": {
"line": 34,
@@ -1230,14 +2784,14 @@
"arguments": [],
"extra": {
"parenthesized": true,
- "parenStart": 748
+ "parenStart": 741
}
}
},
"consequent": {
"type": "BlockStatement",
- "start": 766,
- "end": 783,
+ "start": 759,
+ "end": 776,
"loc": {
"start": {
"line": 34,
@@ -1251,8 +2805,8 @@
"body": [
{
"type": "ReturnStatement",
- "start": 772,
- "end": 779,
+ "start": 765,
+ "end": 772,
"loc": {
"start": {
"line": 35,
@@ -1272,8 +2826,8 @@
},
{
"type": "ExpressionStatement",
- "start": 787,
- "end": 915,
+ "start": 780,
+ "end": 908,
"loc": {
"start": {
"line": 38,
@@ -1286,8 +2840,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 787,
- "end": 914,
+ "start": 780,
+ "end": 907,
"loc": {
"start": {
"line": 38,
@@ -1300,8 +2854,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 787,
- "end": 876,
+ "start": 780,
+ "end": 869,
"loc": {
"start": {
"line": 38,
@@ -1314,8 +2868,8 @@
},
"object": {
"type": "CallExpression",
- "start": 787,
- "end": 870,
+ "start": 780,
+ "end": 863,
"loc": {
"start": {
"line": 38,
@@ -1328,8 +2882,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 787,
- "end": 841,
+ "start": 780,
+ "end": 834,
"loc": {
"start": {
"line": 38,
@@ -1342,8 +2896,8 @@
},
"object": {
"type": "CallExpression",
- "start": 787,
- "end": 836,
+ "start": 780,
+ "end": 829,
"loc": {
"start": {
"line": 38,
@@ -1356,8 +2910,8 @@
},
"callee": {
"type": "Import",
- "start": 787,
- "end": 793,
+ "start": 780,
+ "end": 786,
"loc": {
"start": {
"line": 38,
@@ -1372,8 +2926,8 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 820,
- "end": 835,
+ "start": 813,
+ "end": 828,
"loc": {
"start": {
"line": 38,
@@ -1393,8 +2947,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 794,
- "end": 819,
+ "start": 787,
+ "end": 812,
"loc": {
"start": {
"line": 38,
@@ -1412,8 +2966,8 @@
},
"property": {
"type": "Identifier",
- "start": 837,
- "end": 841,
+ "start": 830,
+ "end": 834,
"loc": {
"start": {
"line": 38,
@@ -1432,8 +2986,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 842,
- "end": 869,
+ "start": 835,
+ "end": 862,
"loc": {
"start": {
"line": 38,
@@ -1451,8 +3005,8 @@
"params": [
{
"type": "Identifier",
- "start": 842,
- "end": 843,
+ "start": 835,
+ "end": 836,
"loc": {
"start": {
"line": 38,
@@ -1469,8 +3023,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 847,
- "end": 869,
+ "start": 840,
+ "end": 862,
"loc": {
"start": {
"line": 38,
@@ -1484,8 +3038,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 853,
- "end": 865,
+ "start": 846,
+ "end": 858,
"loc": {
"start": {
"line": 39,
@@ -1498,8 +3052,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 853,
- "end": 864,
+ "start": 846,
+ "end": 857,
"loc": {
"start": {
"line": 39,
@@ -1512,8 +3066,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 853,
- "end": 862,
+ "start": 846,
+ "end": 855,
"loc": {
"start": {
"line": 39,
@@ -1526,8 +3080,8 @@
},
"object": {
"type": "Identifier",
- "start": 853,
- "end": 854,
+ "start": 846,
+ "end": 847,
"loc": {
"start": {
"line": 39,
@@ -1543,8 +3097,8 @@
},
"property": {
"type": "Identifier",
- "start": 855,
- "end": 862,
+ "start": 848,
+ "end": 855,
"loc": {
"start": {
"line": 39,
@@ -1571,8 +3125,8 @@
},
"property": {
"type": "Identifier",
- "start": 871,
- "end": 876,
+ "start": 864,
+ "end": 869,
"loc": {
"start": {
"line": 40,
@@ -1591,8 +3145,8 @@
"arguments": [
{
"type": "ArrowFunctionExpression",
- "start": 877,
- "end": 913,
+ "start": 870,
+ "end": 906,
"loc": {
"start": {
"line": 40,
@@ -1610,8 +3164,8 @@
"params": [
{
"type": "Identifier",
- "start": 877,
- "end": 880,
+ "start": 870,
+ "end": 873,
"loc": {
"start": {
"line": 40,
@@ -1628,8 +3182,8 @@
],
"body": {
"type": "BlockStatement",
- "start": 884,
- "end": 913,
+ "start": 877,
+ "end": 906,
"loc": {
"start": {
"line": 40,
@@ -1643,8 +3197,8 @@
"body": [
{
"type": "ExpressionStatement",
- "start": 890,
- "end": 909,
+ "start": 883,
+ "end": 902,
"loc": {
"start": {
"line": 41,
@@ -1657,8 +3211,8 @@
},
"expression": {
"type": "CallExpression",
- "start": 890,
- "end": 908,
+ "start": 883,
+ "end": 901,
"loc": {
"start": {
"line": 41,
@@ -1671,8 +3225,8 @@
},
"callee": {
"type": "MemberExpression",
- "start": 890,
- "end": 903,
+ "start": 883,
+ "end": 896,
"loc": {
"start": {
"line": 41,
@@ -1685,8 +3239,8 @@
},
"object": {
"type": "Identifier",
- "start": 890,
- "end": 897,
+ "start": 883,
+ "end": 890,
"loc": {
"start": {
"line": 41,
@@ -1702,8 +3256,8 @@
},
"property": {
"type": "Identifier",
- "start": 898,
- "end": 903,
+ "start": 891,
+ "end": 896,
"loc": {
"start": {
"line": 41,
@@ -1722,8 +3276,8 @@
"arguments": [
{
"type": "Identifier",
- "start": 904,
- "end": 907,
+ "start": 897,
+ "end": 900,
"loc": {
"start": {
"line": 41,
@@ -1770,24 +3324,9 @@
],
"trailingComments": []
},
- "leadingComments": [
- {
- "type": "CommentBlock",
- "value": "*\n * The public entry point\n * @param {Object} userConfig User's config\n ",
- "start": 307,
- "end": 385,
- "loc": {
- "start": {
- "line": 17,
- "column": 0
- },
- "end": {
- "line": 20,
- "column": 3
- }
- }
- }
- ]
+ "specifiers": null,
+ "source": null,
+ "leadingComments": null
}
],
"directives": [
@@ -2011,8 +3550,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 794,
- "end": 819,
+ "start": 787,
+ "end": 812,
"loc": {
"start": {
"line": 38,
@@ -2543,34 +4082,6 @@
}
}
},
- {
- "type": {
- "label": "export",
- "keyword": "export",
- "beforeExpr": false,
- "startsExpr": false,
- "rightAssociative": false,
- "isLoop": false,
- "isAssign": false,
- "prefix": false,
- "postfix": false,
- "binop": null,
- "updateContext": null
- },
- "value": "export",
- "start": 387,
- "end": 393,
- "loc": {
- "start": {
- "line": 22,
- "column": 0
- },
- "end": {
- "line": 22,
- "column": 6
- }
- }
- },
{
"type": {
"label": "function",
@@ -2585,16 +4096,16 @@
"binop": null
},
"value": "function",
- "start": 394,
- "end": 402,
+ "start": 387,
+ "end": 395,
"loc": {
"start": {
"line": 22,
- "column": 7
+ "column": 0
},
"end": {
"line": 22,
- "column": 15
+ "column": 8
}
}
},
@@ -2611,16 +4122,16 @@
"binop": null
},
"value": "init",
- "start": 403,
- "end": 407,
+ "start": 396,
+ "end": 400,
"loc": {
"start": {
"line": 22,
- "column": 16
+ "column": 9
},
"end": {
"line": 22,
- "column": 20
+ "column": 13
}
}
},
@@ -2636,16 +4147,16 @@
"postfix": false,
"binop": null
},
- "start": 407,
- "end": 408,
+ "start": 400,
+ "end": 401,
"loc": {
"start": {
"line": 22,
- "column": 20
+ "column": 13
},
"end": {
"line": 22,
- "column": 21
+ "column": 14
}
}
},
@@ -2662,16 +4173,16 @@
"binop": null
},
"value": "userConfig",
- "start": 408,
- "end": 418,
+ "start": 401,
+ "end": 411,
"loc": {
"start": {
"line": 22,
- "column": 21
+ "column": 14
},
"end": {
"line": 22,
- "column": 31
+ "column": 24
}
}
},
@@ -2687,16 +4198,16 @@
"postfix": false,
"binop": null
},
- "start": 418,
- "end": 419,
+ "start": 411,
+ "end": 412,
"loc": {
"start": {
"line": 22,
- "column": 31
+ "column": 24
},
"end": {
"line": 22,
- "column": 32
+ "column": 25
}
}
},
@@ -2712,16 +4223,16 @@
"postfix": false,
"binop": null
},
- "start": 419,
- "end": 420,
+ "start": 412,
+ "end": 413,
"loc": {
"start": {
"line": 22,
- "column": 32
+ "column": 25
},
"end": {
"line": 22,
- "column": 33
+ "column": 26
}
}
},
@@ -2738,8 +4249,8 @@
"binop": null
},
"value": "userConfig",
- "start": 424,
- "end": 434,
+ "start": 417,
+ "end": 427,
"loc": {
"start": {
"line": 24,
@@ -2765,8 +4276,8 @@
"updateContext": null
},
"value": "=",
- "start": 435,
- "end": 436,
+ "start": 428,
+ "end": 429,
"loc": {
"start": {
"line": 24,
@@ -2793,8 +4304,8 @@
"updateContext": null
},
"value": "typeof",
- "start": 437,
- "end": 443,
+ "start": 430,
+ "end": 436,
"loc": {
"start": {
"line": 24,
@@ -2819,8 +4330,8 @@
"binop": null
},
"value": "userConfig",
- "start": 444,
- "end": 454,
+ "start": 437,
+ "end": 447,
"loc": {
"start": {
"line": 24,
@@ -2846,8 +4357,8 @@
"updateContext": null
},
"value": "===",
- "start": 455,
- "end": 458,
+ "start": 448,
+ "end": 451,
"loc": {
"start": {
"line": 24,
@@ -2873,8 +4384,8 @@
"updateContext": null
},
"value": "undefined",
- "start": 459,
- "end": 470,
+ "start": 452,
+ "end": 463,
"loc": {
"start": {
"line": 24,
@@ -2899,8 +4410,8 @@
"binop": null,
"updateContext": null
},
- "start": 471,
- "end": 472,
+ "start": 464,
+ "end": 465,
"loc": {
"start": {
"line": 24,
@@ -2924,8 +4435,8 @@
"postfix": false,
"binop": null
},
- "start": 473,
- "end": 474,
+ "start": 466,
+ "end": 467,
"loc": {
"start": {
"line": 24,
@@ -2949,8 +4460,8 @@
"postfix": false,
"binop": null
},
- "start": 474,
- "end": 475,
+ "start": 467,
+ "end": 468,
"loc": {
"start": {
"line": 24,
@@ -2975,8 +4486,8 @@
"binop": null,
"updateContext": null
},
- "start": 476,
- "end": 477,
+ "start": 469,
+ "end": 470,
"loc": {
"start": {
"line": 24,
@@ -3001,8 +4512,8 @@
"binop": null
},
"value": "userConfig",
- "start": 478,
- "end": 488,
+ "start": 471,
+ "end": 481,
"loc": {
"start": {
"line": 24,
@@ -3027,8 +4538,8 @@
"binop": null,
"updateContext": null
},
- "start": 488,
- "end": 489,
+ "start": 481,
+ "end": 482,
"loc": {
"start": {
"line": 24,
@@ -3055,8 +4566,8 @@
"updateContext": null
},
"value": "if",
- "start": 493,
- "end": 495,
+ "start": 486,
+ "end": 488,
"loc": {
"start": {
"line": 26,
@@ -3080,8 +4591,8 @@
"postfix": false,
"binop": null
},
- "start": 496,
- "end": 497,
+ "start": 489,
+ "end": 490,
"loc": {
"start": {
"line": 26,
@@ -3106,8 +4617,8 @@
"binop": null
},
"value": "process",
- "start": 497,
- "end": 504,
+ "start": 490,
+ "end": 497,
"loc": {
"start": {
"line": 26,
@@ -3132,8 +4643,8 @@
"binop": null,
"updateContext": null
},
- "start": 504,
- "end": 505,
+ "start": 497,
+ "end": 498,
"loc": {
"start": {
"line": 26,
@@ -3158,8 +4669,8 @@
"binop": null
},
"value": "env",
- "start": 505,
- "end": 508,
+ "start": 498,
+ "end": 501,
"loc": {
"start": {
"line": 26,
@@ -3184,8 +4695,8 @@
"binop": null,
"updateContext": null
},
- "start": 508,
- "end": 509,
+ "start": 501,
+ "end": 502,
"loc": {
"start": {
"line": 26,
@@ -3210,8 +4721,8 @@
"binop": null
},
"value": "NODE_ENV",
- "start": 509,
- "end": 517,
+ "start": 502,
+ "end": 510,
"loc": {
"start": {
"line": 26,
@@ -3237,8 +4748,8 @@
"updateContext": null
},
"value": "===",
- "start": 518,
- "end": 521,
+ "start": 511,
+ "end": 514,
"loc": {
"start": {
"line": 26,
@@ -3264,8 +4775,8 @@
"updateContext": null
},
"value": "development",
- "start": 522,
- "end": 535,
+ "start": 515,
+ "end": 528,
"loc": {
"start": {
"line": 26,
@@ -3289,8 +4800,8 @@
"postfix": false,
"binop": null
},
- "start": 535,
- "end": 536,
+ "start": 528,
+ "end": 529,
"loc": {
"start": {
"line": 26,
@@ -3314,8 +4825,8 @@
"postfix": false,
"binop": null
},
- "start": 536,
- "end": 537,
+ "start": 529,
+ "end": 530,
"loc": {
"start": {
"line": 26,
@@ -3340,8 +4851,8 @@
"binop": null
},
"value": "console",
- "start": 542,
- "end": 549,
+ "start": 535,
+ "end": 542,
"loc": {
"start": {
"line": 27,
@@ -3366,8 +4877,8 @@
"binop": null,
"updateContext": null
},
- "start": 549,
- "end": 550,
+ "start": 542,
+ "end": 543,
"loc": {
"start": {
"line": 27,
@@ -3392,8 +4903,8 @@
"binop": null
},
"value": "log",
- "start": 550,
- "end": 553,
+ "start": 543,
+ "end": 546,
"loc": {
"start": {
"line": 27,
@@ -3417,8 +4928,8 @@
"postfix": false,
"binop": null
},
- "start": 553,
- "end": 554,
+ "start": 546,
+ "end": 547,
"loc": {
"start": {
"line": 27,
@@ -3444,8 +4955,8 @@
"updateContext": null
},
"value": "--- --- --- --- ---",
- "start": 554,
- "end": 575,
+ "start": 547,
+ "end": 568,
"loc": {
"start": {
"line": 27,
@@ -3469,8 +4980,8 @@
"postfix": false,
"binop": null
},
- "start": 575,
- "end": 576,
+ "start": 568,
+ "end": 569,
"loc": {
"start": {
"line": 27,
@@ -3495,8 +5006,8 @@
"binop": null,
"updateContext": null
},
- "start": 576,
- "end": 577,
+ "start": 569,
+ "end": 570,
"loc": {
"start": {
"line": 27,
@@ -3521,8 +5032,8 @@
"binop": null
},
"value": "console",
- "start": 582,
- "end": 589,
+ "start": 575,
+ "end": 582,
"loc": {
"start": {
"line": 28,
@@ -3547,8 +5058,8 @@
"binop": null,
"updateContext": null
},
- "start": 589,
- "end": 590,
+ "start": 582,
+ "end": 583,
"loc": {
"start": {
"line": 28,
@@ -3573,8 +5084,8 @@
"binop": null
},
"value": "log",
- "start": 590,
- "end": 593,
+ "start": 583,
+ "end": 586,
"loc": {
"start": {
"line": 28,
@@ -3598,8 +5109,8 @@
"postfix": false,
"binop": null
},
- "start": 593,
- "end": 594,
+ "start": 586,
+ "end": 587,
"loc": {
"start": {
"line": 28,
@@ -3625,8 +5136,8 @@
"updateContext": null
},
"value": "Hey that, notice that you are now in DEV MODE.",
- "start": 594,
- "end": 642,
+ "start": 587,
+ "end": 635,
"loc": {
"start": {
"line": 28,
@@ -3650,8 +5161,8 @@
"postfix": false,
"binop": null
},
- "start": 642,
- "end": 643,
+ "start": 635,
+ "end": 636,
"loc": {
"start": {
"line": 28,
@@ -3676,8 +5187,8 @@
"binop": null,
"updateContext": null
},
- "start": 643,
- "end": 644,
+ "start": 636,
+ "end": 637,
"loc": {
"start": {
"line": 28,
@@ -3702,8 +5213,8 @@
"binop": null
},
"value": "console",
- "start": 649,
- "end": 656,
+ "start": 642,
+ "end": 649,
"loc": {
"start": {
"line": 29,
@@ -3728,8 +5239,8 @@
"binop": null,
"updateContext": null
},
- "start": 656,
- "end": 657,
+ "start": 649,
+ "end": 650,
"loc": {
"start": {
"line": 29,
@@ -3754,8 +5265,8 @@
"binop": null
},
"value": "log",
- "start": 657,
- "end": 660,
+ "start": 650,
+ "end": 653,
"loc": {
"start": {
"line": 29,
@@ -3779,8 +5290,8 @@
"postfix": false,
"binop": null
},
- "start": 660,
- "end": 661,
+ "start": 653,
+ "end": 654,
"loc": {
"start": {
"line": 29,
@@ -3806,8 +5317,8 @@
"updateContext": null
},
"value": "--- --- --- --- ---",
- "start": 661,
- "end": 682,
+ "start": 654,
+ "end": 675,
"loc": {
"start": {
"line": 29,
@@ -3831,8 +5342,8 @@
"postfix": false,
"binop": null
},
- "start": 682,
- "end": 683,
+ "start": 675,
+ "end": 676,
"loc": {
"start": {
"line": 29,
@@ -3857,8 +5368,8 @@
"binop": null,
"updateContext": null
},
- "start": 683,
- "end": 684,
+ "start": 676,
+ "end": 677,
"loc": {
"start": {
"line": 29,
@@ -3882,8 +5393,8 @@
"postfix": false,
"binop": null
},
- "start": 687,
- "end": 688,
+ "start": 680,
+ "end": 681,
"loc": {
"start": {
"line": 30,
@@ -3908,8 +5419,8 @@
"binop": null
},
"value": "configApplyer",
- "start": 692,
- "end": 705,
+ "start": 685,
+ "end": 698,
"loc": {
"start": {
"line": 32,
@@ -3933,8 +5444,8 @@
"postfix": false,
"binop": null
},
- "start": 705,
- "end": 706,
+ "start": 698,
+ "end": 699,
"loc": {
"start": {
"line": 32,
@@ -3959,8 +5470,8 @@
"binop": null
},
"value": "userConfig",
- "start": 706,
- "end": 716,
+ "start": 699,
+ "end": 709,
"loc": {
"start": {
"line": 32,
@@ -3984,8 +5495,8 @@
"postfix": false,
"binop": null
},
- "start": 716,
- "end": 717,
+ "start": 709,
+ "end": 710,
"loc": {
"start": {
"line": 32,
@@ -4010,8 +5521,8 @@
"binop": null,
"updateContext": null
},
- "start": 717,
- "end": 718,
+ "start": 710,
+ "end": 711,
"loc": {
"start": {
"line": 32,
@@ -4038,8 +5549,8 @@
"updateContext": null
},
"value": "if",
- "start": 722,
- "end": 724,
+ "start": 715,
+ "end": 717,
"loc": {
"start": {
"line": 34,
@@ -4063,8 +5574,8 @@
"postfix": false,
"binop": null
},
- "start": 724,
- "end": 725,
+ "start": 717,
+ "end": 718,
"loc": {
"start": {
"line": 34,
@@ -4088,8 +5599,8 @@
"postfix": false,
"binop": null
},
- "start": 725,
- "end": 726,
+ "start": 718,
+ "end": 719,
"loc": {
"start": {
"line": 34,
@@ -4115,8 +5626,8 @@
"updateContext": null
},
"value": "!",
- "start": 726,
- "end": 727,
+ "start": 719,
+ "end": 720,
"loc": {
"start": {
"line": 34,
@@ -4141,8 +5652,8 @@
"binop": null
},
"value": "config",
- "start": 727,
- "end": 733,
+ "start": 720,
+ "end": 726,
"loc": {
"start": {
"line": 34,
@@ -4167,8 +5678,8 @@
"binop": null,
"updateContext": null
},
- "start": 733,
- "end": 734,
+ "start": 726,
+ "end": 727,
"loc": {
"start": {
"line": 34,
@@ -4193,8 +5704,8 @@
"binop": null
},
"value": "mobile",
- "start": 734,
- "end": 740,
+ "start": 727,
+ "end": 733,
"loc": {
"start": {
"line": 34,
@@ -4219,8 +5730,8 @@
"binop": null,
"updateContext": null
},
- "start": 740,
- "end": 741,
+ "start": 733,
+ "end": 734,
"loc": {
"start": {
"line": 34,
@@ -4245,8 +5756,8 @@
"binop": null
},
"value": "show",
- "start": 741,
- "end": 745,
+ "start": 734,
+ "end": 738,
"loc": {
"start": {
"line": 34,
@@ -4270,8 +5781,8 @@
"postfix": false,
"binop": null
},
- "start": 745,
- "end": 746,
+ "start": 738,
+ "end": 739,
"loc": {
"start": {
"line": 34,
@@ -4297,8 +5808,8 @@
"updateContext": null
},
"value": "&&",
- "start": 746,
- "end": 748,
+ "start": 739,
+ "end": 741,
"loc": {
"start": {
"line": 34,
@@ -4322,8 +5833,8 @@
"postfix": false,
"binop": null
},
- "start": 748,
- "end": 749,
+ "start": 741,
+ "end": 742,
"loc": {
"start": {
"line": 34,
@@ -4348,8 +5859,8 @@
"binop": null
},
"value": "device",
- "start": 749,
- "end": 755,
+ "start": 742,
+ "end": 748,
"loc": {
"start": {
"line": 34,
@@ -4374,8 +5885,8 @@
"binop": null,
"updateContext": null
},
- "start": 755,
- "end": 756,
+ "start": 748,
+ "end": 749,
"loc": {
"start": {
"line": 34,
@@ -4400,8 +5911,8 @@
"binop": null
},
"value": "mobile",
- "start": 756,
- "end": 762,
+ "start": 749,
+ "end": 755,
"loc": {
"start": {
"line": 34,
@@ -4425,8 +5936,8 @@
"postfix": false,
"binop": null
},
- "start": 762,
- "end": 763,
+ "start": 755,
+ "end": 756,
"loc": {
"start": {
"line": 34,
@@ -4450,8 +5961,8 @@
"postfix": false,
"binop": null
},
- "start": 763,
- "end": 764,
+ "start": 756,
+ "end": 757,
"loc": {
"start": {
"line": 34,
@@ -4475,8 +5986,8 @@
"postfix": false,
"binop": null
},
- "start": 764,
- "end": 765,
+ "start": 757,
+ "end": 758,
"loc": {
"start": {
"line": 34,
@@ -4500,8 +6011,8 @@
"postfix": false,
"binop": null
},
- "start": 765,
- "end": 766,
+ "start": 758,
+ "end": 759,
"loc": {
"start": {
"line": 34,
@@ -4525,8 +6036,8 @@
"postfix": false,
"binop": null
},
- "start": 766,
- "end": 767,
+ "start": 759,
+ "end": 760,
"loc": {
"start": {
"line": 34,
@@ -4553,8 +6064,8 @@
"updateContext": null
},
"value": "return",
- "start": 772,
- "end": 778,
+ "start": 765,
+ "end": 771,
"loc": {
"start": {
"line": 35,
@@ -4579,8 +6090,8 @@
"binop": null,
"updateContext": null
},
- "start": 778,
- "end": 779,
+ "start": 771,
+ "end": 772,
"loc": {
"start": {
"line": 35,
@@ -4604,8 +6115,8 @@
"postfix": false,
"binop": null
},
- "start": 782,
- "end": 783,
+ "start": 775,
+ "end": 776,
"loc": {
"start": {
"line": 36,
@@ -4632,8 +6143,8 @@
"updateContext": null
},
"value": "import",
- "start": 787,
- "end": 793,
+ "start": 780,
+ "end": 786,
"loc": {
"start": {
"line": 38,
@@ -4657,8 +6168,8 @@
"postfix": false,
"binop": null
},
- "start": 793,
- "end": 794,
+ "start": 786,
+ "end": 787,
"loc": {
"start": {
"line": 38,
@@ -4673,8 +6184,8 @@
{
"type": "CommentBlock",
"value": " webpackMode: \"lazy\" ",
- "start": 794,
- "end": 819,
+ "start": 787,
+ "end": 812,
"loc": {
"start": {
"line": 38,
@@ -4700,8 +6211,8 @@
"updateContext": null
},
"value": "./_cLive2DApp",
- "start": 820,
- "end": 835,
+ "start": 813,
+ "end": 828,
"loc": {
"start": {
"line": 38,
@@ -4725,8 +6236,8 @@
"postfix": false,
"binop": null
},
- "start": 835,
- "end": 836,
+ "start": 828,
+ "end": 829,
"loc": {
"start": {
"line": 38,
@@ -4751,8 +6262,8 @@
"binop": null,
"updateContext": null
},
- "start": 836,
- "end": 837,
+ "start": 829,
+ "end": 830,
"loc": {
"start": {
"line": 38,
@@ -4777,8 +6288,8 @@
"binop": null
},
"value": "then",
- "start": 837,
- "end": 841,
+ "start": 830,
+ "end": 834,
"loc": {
"start": {
"line": 38,
@@ -4802,8 +6313,8 @@
"postfix": false,
"binop": null
},
- "start": 841,
- "end": 842,
+ "start": 834,
+ "end": 835,
"loc": {
"start": {
"line": 38,
@@ -4828,8 +6339,8 @@
"binop": null
},
"value": "f",
- "start": 842,
- "end": 843,
+ "start": 835,
+ "end": 836,
"loc": {
"start": {
"line": 38,
@@ -4854,8 +6365,8 @@
"binop": null,
"updateContext": null
},
- "start": 844,
- "end": 846,
+ "start": 837,
+ "end": 839,
"loc": {
"start": {
"line": 38,
@@ -4879,8 +6390,8 @@
"postfix": false,
"binop": null
},
- "start": 847,
- "end": 848,
+ "start": 840,
+ "end": 841,
"loc": {
"start": {
"line": 38,
@@ -4905,8 +6416,8 @@
"binop": null
},
"value": "f",
- "start": 853,
- "end": 854,
+ "start": 846,
+ "end": 847,
"loc": {
"start": {
"line": 39,
@@ -4931,8 +6442,8 @@
"binop": null,
"updateContext": null
},
- "start": 854,
- "end": 855,
+ "start": 847,
+ "end": 848,
"loc": {
"start": {
"line": 39,
@@ -4959,8 +6470,8 @@
"updateContext": null
},
"value": "default",
- "start": 855,
- "end": 862,
+ "start": 848,
+ "end": 855,
"loc": {
"start": {
"line": 39,
@@ -4984,8 +6495,8 @@
"postfix": false,
"binop": null
},
- "start": 862,
- "end": 863,
+ "start": 855,
+ "end": 856,
"loc": {
"start": {
"line": 39,
@@ -5009,8 +6520,8 @@
"postfix": false,
"binop": null
},
- "start": 863,
- "end": 864,
+ "start": 856,
+ "end": 857,
"loc": {
"start": {
"line": 39,
@@ -5035,8 +6546,8 @@
"binop": null,
"updateContext": null
},
- "start": 864,
- "end": 865,
+ "start": 857,
+ "end": 858,
"loc": {
"start": {
"line": 39,
@@ -5060,8 +6571,8 @@
"postfix": false,
"binop": null
},
- "start": 868,
- "end": 869,
+ "start": 861,
+ "end": 862,
"loc": {
"start": {
"line": 40,
@@ -5085,8 +6596,8 @@
"postfix": false,
"binop": null
},
- "start": 869,
- "end": 870,
+ "start": 862,
+ "end": 863,
"loc": {
"start": {
"line": 40,
@@ -5111,8 +6622,8 @@
"binop": null,
"updateContext": null
},
- "start": 870,
- "end": 871,
+ "start": 863,
+ "end": 864,
"loc": {
"start": {
"line": 40,
@@ -5139,8 +6650,8 @@
"updateContext": null
},
"value": "catch",
- "start": 871,
- "end": 876,
+ "start": 864,
+ "end": 869,
"loc": {
"start": {
"line": 40,
@@ -5164,8 +6675,8 @@
"postfix": false,
"binop": null
},
- "start": 876,
- "end": 877,
+ "start": 869,
+ "end": 870,
"loc": {
"start": {
"line": 40,
@@ -5190,8 +6701,8 @@
"binop": null
},
"value": "err",
- "start": 877,
- "end": 880,
+ "start": 870,
+ "end": 873,
"loc": {
"start": {
"line": 40,
@@ -5216,8 +6727,8 @@
"binop": null,
"updateContext": null
},
- "start": 881,
- "end": 883,
+ "start": 874,
+ "end": 876,
"loc": {
"start": {
"line": 40,
@@ -5241,8 +6752,8 @@
"postfix": false,
"binop": null
},
- "start": 884,
- "end": 885,
+ "start": 877,
+ "end": 878,
"loc": {
"start": {
"line": 40,
@@ -5267,8 +6778,8 @@
"binop": null
},
"value": "console",
- "start": 890,
- "end": 897,
+ "start": 883,
+ "end": 890,
"loc": {
"start": {
"line": 41,
@@ -5293,8 +6804,8 @@
"binop": null,
"updateContext": null
},
- "start": 897,
- "end": 898,
+ "start": 890,
+ "end": 891,
"loc": {
"start": {
"line": 41,
@@ -5319,8 +6830,8 @@
"binop": null
},
"value": "error",
- "start": 898,
- "end": 903,
+ "start": 891,
+ "end": 896,
"loc": {
"start": {
"line": 41,
@@ -5344,8 +6855,8 @@
"postfix": false,
"binop": null
},
- "start": 903,
- "end": 904,
+ "start": 896,
+ "end": 897,
"loc": {
"start": {
"line": 41,
@@ -5370,8 +6881,8 @@
"binop": null
},
"value": "err",
- "start": 904,
- "end": 907,
+ "start": 897,
+ "end": 900,
"loc": {
"start": {
"line": 41,
@@ -5395,8 +6906,8 @@
"postfix": false,
"binop": null
},
- "start": 907,
- "end": 908,
+ "start": 900,
+ "end": 901,
"loc": {
"start": {
"line": 41,
@@ -5421,8 +6932,8 @@
"binop": null,
"updateContext": null
},
- "start": 908,
- "end": 909,
+ "start": 901,
+ "end": 902,
"loc": {
"start": {
"line": 41,
@@ -5446,8 +6957,8 @@
"postfix": false,
"binop": null
},
- "start": 912,
- "end": 913,
+ "start": 905,
+ "end": 906,
"loc": {
"start": {
"line": 42,
@@ -5471,8 +6982,8 @@
"postfix": false,
"binop": null
},
- "start": 913,
- "end": 914,
+ "start": 906,
+ "end": 907,
"loc": {
"start": {
"line": 42,
@@ -5497,8 +7008,8 @@
"binop": null,
"updateContext": null
},
- "start": 914,
- "end": 915,
+ "start": 907,
+ "end": 908,
"loc": {
"start": {
"line": 42,
@@ -5522,8 +7033,8 @@
"postfix": false,
"binop": null
},
- "start": 917,
- "end": 918,
+ "start": 910,
+ "end": 911,
"loc": {
"start": {
"line": 44,
@@ -5537,7 +7048,8 @@
},
{
"type": {
- "label": "eof",
+ "label": "export",
+ "keyword": "export",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
@@ -5548,15 +7060,144 @@
"binop": null,
"updateContext": null
},
- "start": 919,
+ "value": "export",
+ "start": 913,
"end": 919,
"loc": {
"start": {
- "line": 45,
+ "line": 46,
+ "column": 0
+ },
+ "end": {
+ "line": 46,
+ "column": 6
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "{",
+ "beforeExpr": true,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 920,
+ "end": 921,
+ "loc": {
+ "start": {
+ "line": 46,
+ "column": 7
+ },
+ "end": {
+ "line": 46,
+ "column": 8
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "name",
+ "beforeExpr": false,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "value": "init",
+ "start": 924,
+ "end": 928,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 2
+ },
+ "end": {
+ "line": 47,
+ "column": 6
+ }
+ }
+ },
+ {
+ "type": {
+ "label": ",",
+ "beforeExpr": true,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "start": 928,
+ "end": 929,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 6
+ },
+ "end": {
+ "line": 47,
+ "column": 7
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "}",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 930,
+ "end": 931,
+ "loc": {
+ "start": {
+ "line": 48,
+ "column": 0
+ },
+ "end": {
+ "line": 48,
+ "column": 1
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "eof",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "start": 932,
+ "end": 932,
+ "loc": {
+ "start": {
+ "line": 49,
"column": 0
},
"end": {
- "line": 45,
+ "line": 49,
"column": 0
}
}
diff --git a/ghpages/docs/ast/source/wpPublicPath.js.json b/ghpages/docs/ast/source/wpPublicPath.js.json
index b0a84c2..2660b9b 100644
--- a/ghpages/docs/ast/source/wpPublicPath.js.json
+++ b/ghpages/docs/ast/source/wpPublicPath.js.json
@@ -1,63 +1,64 @@
{
"type": "File",
"start": 0,
- "end": 1129,
+ "end": 1396,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
- "line": 45,
+ "line": 61,
"column": 0
}
},
"program": {
"type": "Program",
"start": 0,
- "end": 1129,
+ "end": 1396,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
- "line": 45,
+ "line": 61,
"column": 0
}
},
"sourceType": "module",
"body": [
{
- "type": "FunctionDeclaration",
- "start": 85,
- "end": 894,
+ "type": "Identifier",
+ "start": 254,
+ "end": 1135,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 0
},
"end": {
- "line": 37,
+ "line": 49,
"column": 1
}
},
"id": {
"type": "Identifier",
- "start": 94,
- "end": 108,
+ "start": 263,
+ "end": 277,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 9
},
"end": {
- "line": 8,
+ "line": 15,
"column": 23
},
"identifierName": "getCurrentPath"
},
- "name": "getCurrentPath"
+ "name": "getCurrentPath",
+ "leadingComments": null
},
"generator": false,
"expression": false,
@@ -65,59 +66,59 @@
"params": [],
"body": {
"type": "BlockStatement",
- "start": 110,
- "end": 894,
+ "start": 279,
+ "end": 1135,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 25
},
"end": {
- "line": 37,
+ "line": 49,
"column": 1
}
},
"body": [
{
"type": "VariableDeclaration",
- "start": 115,
- "end": 144,
+ "start": 284,
+ "end": 313,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 2
},
"end": {
- "line": 10,
+ "line": 17,
"column": 31
}
},
"declarations": [
{
"type": "VariableDeclarator",
- "start": 119,
- "end": 143,
+ "start": 288,
+ "end": 312,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 6
},
"end": {
- "line": 10,
+ "line": 17,
"column": 30
}
},
"id": {
"type": "Identifier",
- "start": 119,
- "end": 136,
+ "start": 288,
+ "end": 305,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 6
},
"end": {
- "line": 10,
+ "line": 17,
"column": 23
},
"identifierName": "currentScriptPath"
@@ -126,15 +127,15 @@
},
"init": {
"type": "NullLiteral",
- "start": 139,
- "end": 143,
+ "start": 308,
+ "end": 312,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 26
},
"end": {
- "line": 10,
+ "line": 17,
"column": 30
}
}
@@ -145,73 +146,73 @@
},
{
"type": "TryStatement",
- "start": 148,
- "end": 763,
+ "start": 317,
+ "end": 1103,
"loc": {
"start": {
- "line": 12,
+ "line": 19,
"column": 2
},
"end": {
- "line": 29,
+ "line": 45,
"column": 3
}
},
"block": {
"type": "BlockStatement",
- "start": 151,
- "end": 421,
+ "start": 320,
+ "end": 590,
"loc": {
"start": {
- "line": 12,
+ "line": 19,
"column": 5
},
"end": {
- "line": 20,
+ "line": 27,
"column": 3
}
},
"body": [
{
"type": "VariableDeclaration",
- "start": 275,
- "end": 325,
+ "start": 444,
+ "end": 494,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 4
},
"end": {
- "line": 18,
+ "line": 25,
"column": 54
}
},
"declarations": [
{
"type": "VariableDeclarator",
- "start": 279,
- "end": 324,
+ "start": 448,
+ "end": 493,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 8
},
"end": {
- "line": 18,
+ "line": 25,
"column": 53
}
},
"id": {
"type": "Identifier",
- "start": 279,
- "end": 299,
+ "start": 448,
+ "end": 468,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 8
},
"end": {
- "line": 18,
+ "line": 25,
"column": 28
},
"identifierName": "currentScriptElement"
@@ -221,29 +222,29 @@
},
"init": {
"type": "MemberExpression",
- "start": 302,
- "end": 324,
+ "start": 471,
+ "end": 493,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 31
},
"end": {
- "line": 18,
+ "line": 25,
"column": 53
}
},
"object": {
"type": "Identifier",
- "start": 302,
- "end": 310,
+ "start": 471,
+ "end": 479,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 31
},
"end": {
- "line": 18,
+ "line": 25,
"column": 39
},
"identifierName": "document"
@@ -252,15 +253,15 @@
},
"property": {
"type": "Identifier",
- "start": 311,
- "end": 324,
+ "start": 480,
+ "end": 493,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 40
},
"end": {
- "line": 18,
+ "line": 25,
"column": 53
},
"identifierName": "currentScript"
@@ -277,15 +278,15 @@
{
"type": "CommentLine",
"value": " FF, Chrome",
- "start": 157,
- "end": 170,
+ "start": 326,
+ "end": 339,
"loc": {
"start": {
- "line": 13,
+ "line": 20,
"column": 4
},
"end": {
- "line": 13,
+ "line": 20,
"column": 17
}
}
@@ -293,15 +294,15 @@
{
"type": "CommentLine",
"value": " use their API to get the path of current script",
- "start": 175,
- "end": 225,
+ "start": 344,
+ "end": 394,
"loc": {
"start": {
- "line": 14,
+ "line": 21,
"column": 4
},
"end": {
- "line": 14,
+ "line": 21,
"column": 54
}
}
@@ -309,15 +310,15 @@
{
"type": "CommentLine",
"value": " a.b();",
- "start": 231,
- "end": 240,
+ "start": 400,
+ "end": 409,
"loc": {
"start": {
- "line": 16,
+ "line": 23,
"column": 4
},
"end": {
- "line": 16,
+ "line": 23,
"column": 13
}
}
@@ -325,15 +326,15 @@
{
"type": "CommentLine",
"value": " console.log('Stage1');",
- "start": 245,
- "end": 270,
+ "start": 414,
+ "end": 439,
"loc": {
"start": {
- "line": 17,
+ "line": 24,
"column": 4
},
"end": {
- "line": 17,
+ "line": 24,
"column": 29
}
}
@@ -342,44 +343,44 @@
},
{
"type": "ExpressionStatement",
- "start": 330,
- "end": 417,
+ "start": 499,
+ "end": 586,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 4
},
"end": {
- "line": 19,
+ "line": 26,
"column": 91
}
},
"expression": {
"type": "AssignmentExpression",
- "start": 330,
- "end": 416,
+ "start": 499,
+ "end": 585,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 4
},
"end": {
- "line": 19,
+ "line": 26,
"column": 90
}
},
"operator": "=",
"left": {
"type": "Identifier",
- "start": 330,
- "end": 347,
+ "start": 499,
+ "end": 516,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 4
},
"end": {
- "line": 19,
+ "line": 26,
"column": 21
},
"identifierName": "currentScriptPath"
@@ -388,71 +389,71 @@
},
"right": {
"type": "CallExpression",
- "start": 350,
- "end": 416,
+ "start": 519,
+ "end": 585,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 90
}
},
"callee": {
"type": "MemberExpression",
- "start": 350,
- "end": 398,
+ "start": 519,
+ "end": 567,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 72
}
},
"object": {
"type": "CallExpression",
- "start": 350,
- "end": 390,
+ "start": 519,
+ "end": 559,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 64
}
},
"callee": {
"type": "MemberExpression",
- "start": 350,
- "end": 383,
+ "start": 519,
+ "end": 552,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 57
}
},
"object": {
"type": "Identifier",
- "start": 350,
- "end": 370,
+ "start": 519,
+ "end": 539,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 44
},
"identifierName": "currentScriptElement"
@@ -461,15 +462,15 @@
},
"property": {
"type": "Identifier",
- "start": 371,
- "end": 383,
+ "start": 540,
+ "end": 552,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 45
},
"end": {
- "line": 19,
+ "line": 26,
"column": 57
},
"identifierName": "getAttribute"
@@ -481,15 +482,15 @@
"arguments": [
{
"type": "StringLiteral",
- "start": 384,
- "end": 389,
+ "start": 553,
+ "end": 558,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 58
},
"end": {
- "line": 19,
+ "line": 26,
"column": 63
}
},
@@ -503,15 +504,15 @@
},
"property": {
"type": "Identifier",
- "start": 391,
- "end": 398,
+ "start": 560,
+ "end": 567,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 65
},
"end": {
- "line": 19,
+ "line": 26,
"column": 72
},
"identifierName": "replace"
@@ -523,15 +524,15 @@
"arguments": [
{
"type": "RegExpLiteral",
- "start": 399,
- "end": 411,
+ "start": 568,
+ "end": 580,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 73
},
"end": {
- "line": 19,
+ "line": 26,
"column": 85
}
},
@@ -543,15 +544,15 @@
},
{
"type": "StringLiteral",
- "start": 413,
- "end": 415,
+ "start": 582,
+ "end": 584,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 87
},
"end": {
- "line": 19,
+ "line": 26,
"column": 89
}
},
@@ -570,29 +571,29 @@
},
"handler": {
"type": "CatchClause",
- "start": 421,
- "end": 763,
+ "start": 590,
+ "end": 1103,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 3
},
"end": {
- "line": 29,
+ "line": 45,
"column": 3
}
},
"param": {
"type": "Identifier",
- "start": 427,
- "end": 428,
+ "start": 596,
+ "end": 597,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 9
},
"end": {
- "line": 20,
+ "line": 27,
"column": 10
},
"identifierName": "e"
@@ -601,59 +602,59 @@
},
"body": {
"type": "BlockStatement",
- "start": 429,
- "end": 763,
+ "start": 598,
+ "end": 1103,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 11
},
"end": {
- "line": 29,
+ "line": 45,
"column": 3
}
},
"body": [
{
"type": "VariableDeclaration",
- "start": 501,
- "end": 648,
+ "start": 694,
+ "end": 797,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 4
},
"end": {
- "line": 26,
- "column": 38
+ "line": 34,
+ "column": 51
}
},
"declarations": [
{
"type": "VariableDeclarator",
- "start": 505,
- "end": 551,
+ "start": 698,
+ "end": 744,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 8
},
"end": {
- "line": 24,
+ "line": 33,
"column": 54
}
},
"id": {
"type": "Identifier",
- "start": 505,
- "end": 510,
+ "start": 698,
+ "end": 703,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 8
},
"end": {
- "line": 24,
+ "line": 33,
"column": 13
},
"identifierName": "stack"
@@ -663,57 +664,57 @@
},
"init": {
"type": "LogicalExpression",
- "start": 513,
- "end": 551,
+ "start": 706,
+ "end": 744,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 16
},
"end": {
- "line": 24,
+ "line": 33,
"column": 54
}
},
"left": {
"type": "LogicalExpression",
- "start": 513,
- "end": 535,
+ "start": 706,
+ "end": 728,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 16
},
"end": {
- "line": 24,
+ "line": 33,
"column": 38
}
},
"left": {
"type": "MemberExpression",
- "start": 513,
- "end": 520,
+ "start": 706,
+ "end": 713,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 16
},
"end": {
- "line": 24,
+ "line": 33,
"column": 23
}
},
"object": {
"type": "Identifier",
- "start": 513,
- "end": 514,
+ "start": 706,
+ "end": 707,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 16
},
"end": {
- "line": 24,
+ "line": 33,
"column": 17
},
"identifierName": "e"
@@ -722,15 +723,15 @@
},
"property": {
"type": "Identifier",
- "start": 515,
- "end": 520,
+ "start": 708,
+ "end": 713,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 18
},
"end": {
- "line": 24,
+ "line": 33,
"column": 23
},
"identifierName": "stack"
@@ -742,29 +743,29 @@
"operator": "||",
"right": {
"type": "MemberExpression",
- "start": 524,
- "end": 535,
+ "start": 717,
+ "end": 728,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 27
},
"end": {
- "line": 24,
+ "line": 33,
"column": 38
}
},
"object": {
"type": "Identifier",
- "start": 524,
- "end": 525,
+ "start": 717,
+ "end": 718,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 27
},
"end": {
- "line": 24,
+ "line": 33,
"column": 28
},
"identifierName": "e"
@@ -773,15 +774,15 @@
},
"property": {
"type": "Identifier",
- "start": 526,
- "end": 535,
+ "start": 719,
+ "end": 728,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 29
},
"end": {
- "line": 24,
+ "line": 33,
"column": 38
},
"identifierName": "sourceURL"
@@ -794,29 +795,29 @@
"operator": "||",
"right": {
"type": "MemberExpression",
- "start": 539,
- "end": 551,
+ "start": 732,
+ "end": 744,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 42
},
"end": {
- "line": 24,
+ "line": 33,
"column": 54
}
},
"object": {
"type": "Identifier",
- "start": 539,
- "end": 540,
+ "start": 732,
+ "end": 733,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 42
},
"end": {
- "line": 24,
+ "line": 33,
"column": 43
},
"identifierName": "e"
@@ -825,15 +826,15 @@
},
"property": {
"type": "Identifier",
- "start": 541,
- "end": 551,
+ "start": 734,
+ "end": 744,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 44
},
"end": {
- "line": 24,
+ "line": 33,
"column": 54
},
"identifierName": "stacktrace"
@@ -847,29 +848,29 @@
},
{
"type": "VariableDeclarator",
- "start": 557,
- "end": 608,
+ "start": 750,
+ "end": 796,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 4
},
"end": {
- "line": 25,
- "column": 55
+ "line": 34,
+ "column": 50
}
},
"id": {
"type": "Identifier",
- "start": 557,
- "end": 568,
+ "start": 750,
+ "end": 761,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 4
},
"end": {
- "line": 25,
+ "line": 34,
"column": 15
},
"identifierName": "rExtractUri"
@@ -878,96 +879,183 @@
},
"init": {
"type": "RegExpLiteral",
- "start": 571,
- "end": 608,
+ "start": 764,
+ "end": 796,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 18
},
"end": {
- "line": 25,
- "column": 55
+ "line": 34,
+ "column": 50
}
},
"extra": {
- "raw": "/(?:http|https|file):\\/\\/.*?\\/.+?.js/"
+ "raw": "/(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\//"
},
- "pattern": "(?:http|https|file):\\/\\/.*?\\/.+?.js",
+ "pattern": "(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\/",
"flags": ""
}
+ }
+ ],
+ "kind": "let",
+ "leadingComments": [
+ {
+ "type": "CommentLine",
+ "value": " IE 10 +, Safari and Opera 9",
+ "start": 604,
+ "end": 634,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 34
+ }
+ }
},
{
- "type": "VariableDeclarator",
- "start": 614,
- "end": 647,
+ "type": "CommentLine",
+ "value": " console.log('Stage2');",
+ "start": 640,
+ "end": 665,
"loc": {
"start": {
- "line": 26,
+ "line": 30,
"column": 4
},
"end": {
- "line": 26,
- "column": 37
+ "line": 30,
+ "column": 29
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " console.log(e);",
+ "start": 670,
+ "end": 688,
+ "loc": {
+ "start": {
+ "line": 31,
+ "column": 4
+ },
+ "end": {
+ "line": 31,
+ "column": 22
+ }
+ }
+ }
+ ],
+ "trailingComments": [
+ {
+ "type": "CommentLine",
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 42
+ }
+ }
+ }
+ ]
+ },
+ {
+ "type": "VariableDeclaration",
+ "start": 845,
+ "end": 883,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 4
+ },
+ "end": {
+ "line": 36,
+ "column": 42
+ }
+ },
+ "declarations": [
+ {
+ "type": "VariableDeclarator",
+ "start": 849,
+ "end": 882,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 8
+ },
+ "end": {
+ "line": 36,
+ "column": 41
}
},
"id": {
"type": "Identifier",
- "start": 614,
- "end": 621,
+ "start": 849,
+ "end": 856,
"loc": {
"start": {
- "line": 26,
- "column": 4
+ "line": 36,
+ "column": 8
},
"end": {
- "line": 26,
- "column": 11
+ "line": 36,
+ "column": 15
},
"identifierName": "absPath"
},
- "name": "absPath"
+ "name": "absPath",
+ "leadingComments": null
},
"init": {
"type": "CallExpression",
- "start": 624,
- "end": 647,
+ "start": 859,
+ "end": 882,
"loc": {
"start": {
- "line": 26,
- "column": 14
+ "line": 36,
+ "column": 18
},
"end": {
- "line": 26,
- "column": 37
+ "line": 36,
+ "column": 41
}
},
"callee": {
"type": "MemberExpression",
- "start": 624,
- "end": 640,
+ "start": 859,
+ "end": 875,
"loc": {
"start": {
- "line": 26,
- "column": 14
+ "line": 36,
+ "column": 18
},
"end": {
- "line": 26,
- "column": 30
+ "line": 36,
+ "column": 34
}
},
"object": {
"type": "Identifier",
- "start": 624,
- "end": 635,
+ "start": 859,
+ "end": 870,
"loc": {
"start": {
- "line": 26,
- "column": 14
+ "line": 36,
+ "column": 18
},
"end": {
- "line": 26,
- "column": 25
+ "line": 36,
+ "column": 29
},
"identifierName": "rExtractUri"
},
@@ -975,16 +1063,16 @@
},
"property": {
"type": "Identifier",
- "start": 636,
- "end": 640,
+ "start": 871,
+ "end": 875,
"loc": {
"start": {
- "line": 26,
- "column": 26
+ "line": 36,
+ "column": 30
},
"end": {
- "line": 26,
- "column": 30
+ "line": 36,
+ "column": 34
},
"identifierName": "exec"
},
@@ -995,56 +1083,41 @@
"arguments": [
{
"type": "Identifier",
- "start": 641,
- "end": 646,
+ "start": 876,
+ "end": 881,
"loc": {
"start": {
- "line": 26,
- "column": 31
+ "line": 36,
+ "column": 35
},
"end": {
- "line": 26,
- "column": 36
+ "line": 36,
+ "column": 40
},
"identifierName": "stack"
},
"name": "stack"
}
]
- }
+ },
+ "leadingComments": null
}
],
"kind": "let",
"leadingComments": [
{
"type": "CommentLine",
- "value": " IE 10 +, Safari and Opera 9",
- "start": 435,
- "end": 465,
- "loc": {
- "start": {
- "line": 21,
- "column": 4
- },
- "end": {
- "line": 21,
- "column": 34
- }
- }
- },
- {
- "type": "CommentLine",
- "value": " console.log('Stage2');",
- "start": 471,
- "end": 496,
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
"loc": {
"start": {
- "line": 23,
+ "line": 35,
"column": 4
},
"end": {
- "line": 23,
- "column": 29
+ "line": 35,
+ "column": 42
}
}
}
@@ -1052,44 +1125,44 @@
},
{
"type": "ExpressionStatement",
- "start": 653,
- "end": 690,
+ "start": 888,
+ "end": 919,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 4
},
"end": {
- "line": 27,
- "column": 41
+ "line": 37,
+ "column": 35
}
},
"expression": {
"type": "AssignmentExpression",
- "start": 653,
- "end": 689,
+ "start": 888,
+ "end": 918,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 4
},
"end": {
- "line": 27,
- "column": 40
+ "line": 37,
+ "column": 34
}
},
"operator": "=",
"left": {
"type": "Identifier",
- "start": 653,
- "end": 670,
+ "start": 888,
+ "end": 905,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 4
},
"end": {
- "line": 27,
+ "line": 37,
"column": 21
},
"identifierName": "currentScriptPath"
@@ -1097,250 +1170,447 @@
"name": "currentScriptPath"
},
"right": {
- "type": "LogicalExpression",
- "start": 673,
- "end": 689,
+ "type": "MemberExpression",
+ "start": 908,
+ "end": 918,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 24
},
"end": {
- "line": 27,
- "column": 40
+ "line": 37,
+ "column": 34
}
},
- "left": {
- "type": "MemberExpression",
- "start": 673,
- "end": 683,
+ "object": {
+ "type": "Identifier",
+ "start": 908,
+ "end": 915,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 24
},
"end": {
- "line": 27,
- "column": 34
- }
- },
- "object": {
- "type": "Identifier",
- "start": 673,
- "end": 680,
- "loc": {
- "start": {
- "line": 27,
- "column": 24
- },
- "end": {
- "line": 27,
- "column": 31
- },
- "identifierName": "absPath"
- },
- "name": "absPath"
- },
- "property": {
- "type": "NumericLiteral",
- "start": 681,
- "end": 682,
- "loc": {
- "start": {
- "line": 27,
- "column": 32
- },
- "end": {
- "line": 27,
- "column": 33
- }
- },
- "extra": {
- "rawValue": 0,
- "raw": "0"
+ "line": 37,
+ "column": 31
},
- "value": 0
+ "identifierName": "absPath"
},
- "computed": true
+ "name": "absPath"
},
- "operator": "||",
- "right": {
- "type": "StringLiteral",
- "start": 687,
- "end": 689,
+ "property": {
+ "type": "NumericLiteral",
+ "start": 916,
+ "end": 917,
"loc": {
"start": {
- "line": 27,
- "column": 38
+ "line": 37,
+ "column": 32
},
"end": {
- "line": 27,
- "column": 40
+ "line": 37,
+ "column": 33
}
},
"extra": {
- "rawValue": "",
- "raw": "''"
+ "rawValue": 0,
+ "raw": "0"
},
- "value": ""
- }
+ "value": 0
+ },
+ "computed": true
}
}
},
{
- "type": "ExpressionStatement",
- "start": 695,
- "end": 759,
+ "type": "IfStatement",
+ "start": 925,
+ "end": 1098,
"loc": {
"start": {
- "line": 28,
+ "line": 39,
"column": 4
},
"end": {
- "line": 28,
- "column": 68
+ "line": 43,
+ "column": 5
}
},
- "expression": {
- "type": "AssignmentExpression",
- "start": 695,
- "end": 758,
+ "test": {
+ "type": "BinaryExpression",
+ "start": 928,
+ "end": 952,
"loc": {
"start": {
- "line": 28,
- "column": 4
+ "line": 39,
+ "column": 7
},
"end": {
- "line": 28,
- "column": 67
+ "line": 39,
+ "column": 31
}
},
- "operator": "=",
"left": {
"type": "Identifier",
- "start": 695,
- "end": 712,
+ "start": 928,
+ "end": 945,
"loc": {
"start": {
- "line": 28,
- "column": 4
+ "line": 39,
+ "column": 7
},
"end": {
- "line": 28,
- "column": 21
+ "line": 39,
+ "column": 24
},
"identifierName": "currentScriptPath"
},
"name": "currentScriptPath"
},
+ "operator": "===",
"right": {
- "type": "CallExpression",
- "start": 715,
- "end": 758,
+ "type": "StringLiteral",
+ "start": 950,
+ "end": 952,
"loc": {
"start": {
- "line": 28,
- "column": 24
+ "line": 39,
+ "column": 29
},
"end": {
- "line": 28,
- "column": 67
+ "line": 39,
+ "column": 31
}
},
- "callee": {
- "type": "MemberExpression",
- "start": 715,
- "end": 740,
+ "extra": {
+ "rawValue": "",
+ "raw": "''"
+ },
+ "value": ""
+ }
+ },
+ "consequent": {
+ "type": "BlockStatement",
+ "start": 953,
+ "end": 1098,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 32
+ },
+ "end": {
+ "line": 43,
+ "column": 5
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 961,
+ "end": 1013,
"loc": {
"start": {
- "line": 28,
- "column": 24
+ "line": 40,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 49
+ "line": 40,
+ "column": 58
}
},
- "object": {
- "type": "Identifier",
- "start": 715,
- "end": 732,
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 961,
+ "end": 1012,
"loc": {
"start": {
- "line": 28,
- "column": 24
+ "line": 40,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 41
- },
- "identifierName": "currentScriptPath"
+ "line": 40,
+ "column": 57
+ }
},
- "name": "currentScriptPath"
- },
- "property": {
- "type": "Identifier",
- "start": 733,
- "end": 740,
- "loc": {
- "start": {
- "line": 28,
- "column": 42
- },
- "end": {
- "line": 28,
- "column": 49
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 961,
+ "end": 972,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 6
+ },
+ "end": {
+ "line": 40,
+ "column": 17
+ },
+ "identifierName": "rExtractUri"
},
- "identifierName": "replace"
+ "name": "rExtractUri"
},
- "name": "replace"
- },
- "computed": false
+ "right": {
+ "type": "RegExpLiteral",
+ "start": 975,
+ "end": 1012,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 20
+ },
+ "end": {
+ "line": 40,
+ "column": 57
+ }
+ },
+ "extra": {
+ "raw": "/(?:http|https|file):\\/\\/.*?\\/.+?.js/"
+ },
+ "pattern": "(?:http|https|file):\\/\\/.*?\\/.+?.js",
+ "flags": ""
+ }
+ }
},
- "arguments": [
- {
- "type": "RegExpLiteral",
- "start": 741,
- "end": 753,
+ {
+ "type": "ExpressionStatement",
+ "start": 1020,
+ "end": 1054,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 6
+ },
+ "end": {
+ "line": 41,
+ "column": 40
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 1020,
+ "end": 1053,
"loc": {
"start": {
- "line": 28,
- "column": 50
+ "line": 41,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 62
+ "line": 41,
+ "column": 39
}
},
- "extra": {
- "raw": "/[^/\\\\\\\\]+$/"
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 1020,
+ "end": 1027,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 6
+ },
+ "end": {
+ "line": 41,
+ "column": 13
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath"
},
- "pattern": "[^/\\\\\\\\]+$",
- "flags": ""
+ "right": {
+ "type": "CallExpression",
+ "start": 1030,
+ "end": 1053,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 39
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 1030,
+ "end": 1046,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 32
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 1030,
+ "end": 1041,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 27
+ },
+ "identifierName": "rExtractUri"
+ },
+ "name": "rExtractUri"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 1042,
+ "end": 1046,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 28
+ },
+ "end": {
+ "line": 41,
+ "column": 32
+ },
+ "identifierName": "exec"
+ },
+ "name": "exec"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 1047,
+ "end": 1052,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 33
+ },
+ "end": {
+ "line": 41,
+ "column": 38
+ },
+ "identifierName": "stack"
+ },
+ "name": "stack"
+ }
+ ]
+ }
+ }
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 1061,
+ "end": 1092,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 6
+ },
+ "end": {
+ "line": 42,
+ "column": 37
+ }
},
- {
- "type": "StringLiteral",
- "start": 755,
- "end": 757,
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 1061,
+ "end": 1091,
"loc": {
"start": {
- "line": 28,
- "column": 64
+ "line": 42,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 66
+ "line": 42,
+ "column": 36
}
},
- "extra": {
- "rawValue": "",
- "raw": "''"
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 1061,
+ "end": 1078,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 6
+ },
+ "end": {
+ "line": 42,
+ "column": 23
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
},
- "value": ""
+ "right": {
+ "type": "MemberExpression",
+ "start": 1081,
+ "end": 1091,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 26
+ },
+ "end": {
+ "line": 42,
+ "column": 36
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 1081,
+ "end": 1088,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 26
+ },
+ "end": {
+ "line": 42,
+ "column": 33
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath"
+ },
+ "property": {
+ "type": "NumericLiteral",
+ "start": 1089,
+ "end": 1090,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 34
+ },
+ "end": {
+ "line": 42,
+ "column": 35
+ }
+ },
+ "extra": {
+ "rawValue": 0,
+ "raw": "0"
+ },
+ "value": 0
+ },
+ "computed": true
+ }
}
- ]
- }
- }
+ }
+ ],
+ "directives": []
+ },
+ "alternate": null
}
],
"directives": []
@@ -1349,148 +1619,31 @@
"guardedHandlers": [],
"finalizer": null
},
- {
- "type": "IfStatement",
- "start": 767,
- "end": 862,
- "loc": {
- "start": {
- "line": 31,
- "column": 2
- },
- "end": {
- "line": 33,
- "column": 3
- }
- },
- "test": {
- "type": "BinaryExpression",
- "start": 771,
- "end": 797,
- "loc": {
- "start": {
- "line": 31,
- "column": 6
- },
- "end": {
- "line": 31,
- "column": 32
- }
- },
- "left": {
- "type": "Identifier",
- "start": 771,
- "end": 788,
- "loc": {
- "start": {
- "line": 31,
- "column": 6
- },
- "end": {
- "line": 31,
- "column": 23
- },
- "identifierName": "currentScriptPath"
- },
- "name": "currentScriptPath"
- },
- "operator": "===",
- "right": {
- "type": "NullLiteral",
- "start": 793,
- "end": 797,
- "loc": {
- "start": {
- "line": 31,
- "column": 28
- },
- "end": {
- "line": 31,
- "column": 32
- }
- }
- }
- },
- "consequent": {
- "type": "BlockStatement",
- "start": 798,
- "end": 862,
- "loc": {
- "start": {
- "line": 31,
- "column": 33
- },
- "end": {
- "line": 33,
- "column": 3
- }
- },
- "body": [
- {
- "type": "ThrowStatement",
- "start": 804,
- "end": 858,
- "loc": {
- "start": {
- "line": 32,
- "column": 4
- },
- "end": {
- "line": 32,
- "column": 58
- }
- },
- "argument": {
- "type": "StringLiteral",
- "start": 810,
- "end": 857,
- "loc": {
- "start": {
- "line": 32,
- "column": 10
- },
- "end": {
- "line": 32,
- "column": 57
- }
- },
- "extra": {
- "rawValue": "Cannot get currentScriptPath for wpPublicPath",
- "raw": "'Cannot get currentScriptPath for wpPublicPath'"
- },
- "value": "Cannot get currentScriptPath for wpPublicPath"
- }
- }
- ],
- "directives": []
- },
- "alternate": null
- },
{
"type": "ReturnStatement",
- "start": 866,
- "end": 891,
+ "start": 1107,
+ "end": 1132,
"loc": {
"start": {
- "line": 35,
+ "line": 47,
"column": 2
},
"end": {
- "line": 35,
+ "line": 47,
"column": 27
}
},
"argument": {
"type": "Identifier",
- "start": 873,
- "end": 890,
+ "start": 1114,
+ "end": 1131,
"loc": {
"start": {
- "line": 35,
+ "line": 47,
"column": 9
},
"end": {
- "line": 35,
+ "line": 47,
"column": 26
},
"identifierName": "currentScriptPath"
@@ -1502,138 +1655,105 @@
"directives": [],
"trailingComments": null
},
- "trailingComments": [
- {
- "type": "CommentLine",
- "value": " expose the path to the global,",
- "start": 896,
- "end": 929,
- "loc": {
- "start": {
- "line": 39,
- "column": 0
- },
- "end": {
- "line": 39,
- "column": 33
- }
- }
- },
- {
- "type": "CommentLine",
- "value": " and wp will finish the following work",
- "start": 930,
- "end": 970,
- "loc": {
- "start": {
- "line": 40,
- "column": 0
- },
- "end": {
- "line": 40,
- "column": 40
- }
- }
- }
- ]
+ "leadingComments": [],
+ "trailingComments": [],
+ "name": "_"
},
{
- "type": "VariableDeclaration",
- "start": 971,
- "end": 1018,
+ "type": "ExpressionStatement",
+ "start": 1212,
+ "end": 1255,
"loc": {
"start": {
- "line": 41,
+ "line": 53,
"column": 0
},
"end": {
- "line": 41,
- "column": 47
+ "line": 53,
+ "column": 43
}
},
- "declarations": [
- {
- "type": "VariableDeclarator",
- "start": 975,
- "end": 1017,
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 1212,
+ "end": 1254,
+ "loc": {
+ "start": {
+ "line": 53,
+ "column": 0
+ },
+ "end": {
+ "line": 53,
+ "column": 42
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 1212,
+ "end": 1235,
"loc": {
"start": {
- "line": 41,
- "column": 4
+ "line": 53,
+ "column": 0
},
"end": {
- "line": 41,
- "column": 46
- }
+ "line": 53,
+ "column": 23
+ },
+ "identifierName": "__webpack_public_path__"
},
- "id": {
- "type": "Identifier",
- "start": 975,
- "end": 998,
- "loc": {
- "start": {
- "line": 41,
- "column": 4
- },
- "end": {
- "line": 41,
- "column": 27
- },
- "identifierName": "__webpack_public_path__"
+ "name": "__webpack_public_path__",
+ "leadingComments": null
+ },
+ "right": {
+ "type": "CallExpression",
+ "start": 1238,
+ "end": 1254,
+ "loc": {
+ "start": {
+ "line": 53,
+ "column": 26
},
- "name": "__webpack_public_path__",
- "leadingComments": null
+ "end": {
+ "line": 53,
+ "column": 42
+ }
},
- "init": {
- "type": "CallExpression",
- "start": 1001,
- "end": 1017,
+ "callee": {
+ "type": "Identifier",
+ "start": 1238,
+ "end": 1252,
"loc": {
"start": {
- "line": 41,
- "column": 30
+ "line": 53,
+ "column": 26
},
"end": {
- "line": 41,
- "column": 46
- }
- },
- "callee": {
- "type": "Identifier",
- "start": 1001,
- "end": 1015,
- "loc": {
- "start": {
- "line": 41,
- "column": 30
- },
- "end": {
- "line": 41,
- "column": 44
- },
- "identifierName": "getCurrentPath"
+ "line": 53,
+ "column": 40
},
- "name": "getCurrentPath"
+ "identifierName": "getCurrentPath"
},
- "arguments": []
+ "name": "getCurrentPath"
},
- "leadingComments": null
- }
- ],
- "kind": "var",
+ "arguments": []
+ },
+ "leadingComments": null
+ },
"leadingComments": [
{
"type": "CommentLine",
"value": " expose the path to the global,",
- "start": 896,
- "end": 929,
+ "start": 1137,
+ "end": 1170,
"loc": {
"start": {
- "line": 39,
+ "line": 51,
"column": 0
},
"end": {
- "line": 39,
+ "line": 51,
"column": 33
}
}
@@ -1641,15 +1761,15 @@
{
"type": "CommentLine",
"value": " and wp will finish the following work",
- "start": 930,
- "end": 970,
+ "start": 1171,
+ "end": 1211,
"loc": {
"start": {
- "line": 40,
+ "line": 52,
"column": 0
},
"end": {
- "line": 40,
+ "line": 52,
"column": 40
}
}
@@ -1658,71 +1778,71 @@
},
{
"type": "IfStatement",
- "start": 1019,
- "end": 1128,
+ "start": 1256,
+ "end": 1365,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 0
},
"end": {
- "line": 44,
+ "line": 56,
"column": 1
}
},
"test": {
"type": "BinaryExpression",
- "start": 1023,
- "end": 1061,
+ "start": 1260,
+ "end": 1298,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 4
},
"end": {
- "line": 42,
+ "line": 54,
"column": 42
}
},
"left": {
"type": "MemberExpression",
- "start": 1023,
- "end": 1043,
+ "start": 1260,
+ "end": 1280,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 4
},
"end": {
- "line": 42,
+ "line": 54,
"column": 24
}
},
"object": {
"type": "MemberExpression",
- "start": 1023,
- "end": 1034,
+ "start": 1260,
+ "end": 1271,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 4
},
"end": {
- "line": 42,
+ "line": 54,
"column": 15
}
},
"object": {
"type": "Identifier",
- "start": 1023,
- "end": 1030,
+ "start": 1260,
+ "end": 1267,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 4
},
"end": {
- "line": 42,
+ "line": 54,
"column": 11
},
"identifierName": "process"
@@ -1731,15 +1851,15 @@
},
"property": {
"type": "Identifier",
- "start": 1031,
- "end": 1034,
+ "start": 1268,
+ "end": 1271,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 12
},
"end": {
- "line": 42,
+ "line": 54,
"column": 15
},
"identifierName": "env"
@@ -1750,15 +1870,15 @@
},
"property": {
"type": "Identifier",
- "start": 1035,
- "end": 1043,
+ "start": 1272,
+ "end": 1280,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 16
},
"end": {
- "line": 42,
+ "line": 54,
"column": 24
},
"identifierName": "NODE_ENV"
@@ -1770,15 +1890,15 @@
"operator": "===",
"right": {
"type": "StringLiteral",
- "start": 1048,
- "end": 1061,
+ "start": 1285,
+ "end": 1298,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 29
},
"end": {
- "line": 42,
+ "line": 54,
"column": 42
}
},
@@ -1791,72 +1911,72 @@
},
"consequent": {
"type": "BlockStatement",
- "start": 1062,
- "end": 1128,
+ "start": 1299,
+ "end": 1365,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 43
},
"end": {
- "line": 44,
+ "line": 56,
"column": 1
}
},
"body": [
{
"type": "ExpressionStatement",
- "start": 1066,
- "end": 1126,
+ "start": 1303,
+ "end": 1363,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 2
},
"end": {
- "line": 43,
+ "line": 55,
"column": 62
}
},
"expression": {
"type": "CallExpression",
- "start": 1066,
- "end": 1125,
+ "start": 1303,
+ "end": 1362,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 2
},
"end": {
- "line": 43,
+ "line": 55,
"column": 61
}
},
"callee": {
"type": "MemberExpression",
- "start": 1066,
- "end": 1077,
+ "start": 1303,
+ "end": 1314,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 2
},
"end": {
- "line": 43,
+ "line": 55,
"column": 13
}
},
"object": {
"type": "Identifier",
- "start": 1066,
- "end": 1073,
+ "start": 1303,
+ "end": 1310,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 2
},
"end": {
- "line": 43,
+ "line": 55,
"column": 9
},
"identifierName": "console"
@@ -1865,15 +1985,15 @@
},
"property": {
"type": "Identifier",
- "start": 1074,
- "end": 1077,
+ "start": 1311,
+ "end": 1314,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 10
},
"end": {
- "line": 43,
+ "line": 55,
"column": 13
},
"identifierName": "log"
@@ -1885,30 +2005,30 @@
"arguments": [
{
"type": "TemplateLiteral",
- "start": 1078,
- "end": 1124,
+ "start": 1315,
+ "end": 1361,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 14
},
"end": {
- "line": 43,
+ "line": 55,
"column": 60
}
},
"expressions": [
{
"type": "Identifier",
- "start": 1099,
- "end": 1122,
+ "start": 1336,
+ "end": 1359,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 35
},
"end": {
- "line": 43,
+ "line": 55,
"column": 58
},
"identifierName": "__webpack_public_path__"
@@ -1919,15 +2039,15 @@
"quasis": [
{
"type": "TemplateElement",
- "start": 1079,
- "end": 1097,
+ "start": 1316,
+ "end": 1334,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 15
},
"end": {
- "line": 43,
+ "line": 55,
"column": 33
}
},
@@ -1939,15 +2059,15 @@
},
{
"type": "TemplateElement",
- "start": 1123,
- "end": 1123,
+ "start": 1360,
+ "end": 1360,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 59
},
"end": {
- "line": 43,
+ "line": 55,
"column": 59
}
},
@@ -1955,24 +2075,1790 @@
"raw": "",
"cooked": ""
},
- "tail": true
+ "tail": true
+ }
+ ]
+ }
+ ]
+ }
+ }
+ ],
+ "directives": []
+ },
+ "alternate": null
+ },
+ {
+ "type": "ExportNamedDeclaration",
+ "start": 1367,
+ "end": 1395,
+ "loc": {
+ "start": {
+ "line": 58,
+ "column": 0
+ },
+ "end": {
+ "line": 60,
+ "column": 1
+ }
+ },
+ "declaration": null,
+ "specifiers": [
+ {
+ "type": "ExportSpecifier",
+ "start": 1378,
+ "end": 1392,
+ "loc": {
+ "start": {
+ "line": 59,
+ "column": 2
+ },
+ "end": {
+ "line": 59,
+ "column": 16
+ }
+ },
+ "local": {
+ "type": "Identifier",
+ "start": 1378,
+ "end": 1392,
+ "loc": {
+ "start": {
+ "line": 59,
+ "column": 2
+ },
+ "end": {
+ "line": 59,
+ "column": 16
+ },
+ "identifierName": "getCurrentPath"
+ },
+ "name": "getCurrentPath"
+ },
+ "exported": {
+ "type": "Identifier",
+ "start": 1378,
+ "end": 1392,
+ "loc": {
+ "start": {
+ "line": 59,
+ "column": 2
+ },
+ "end": {
+ "line": 59,
+ "column": 16
+ },
+ "identifierName": "getCurrentPath"
+ },
+ "name": "getCurrentPath"
+ }
+ }
+ ],
+ "source": null
+ },
+ {
+ "type": "ExportNamedDeclaration",
+ "start": 1367,
+ "end": 1395,
+ "loc": {
+ "start": {
+ "line": 58,
+ "column": 0
+ },
+ "end": {
+ "line": 60,
+ "column": 1
+ }
+ },
+ "declaration": {
+ "type": "FunctionDeclaration",
+ "start": 254,
+ "end": 1135,
+ "loc": {
+ "start": {
+ "line": 15,
+ "column": 0
+ },
+ "end": {
+ "line": 49,
+ "column": 1
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 263,
+ "end": 277,
+ "loc": {
+ "start": {
+ "line": 15,
+ "column": 9
+ },
+ "end": {
+ "line": 15,
+ "column": 23
+ },
+ "identifierName": "getCurrentPath"
+ },
+ "name": "getCurrentPath",
+ "leadingComments": null
+ },
+ "generator": false,
+ "expression": false,
+ "async": false,
+ "params": [],
+ "body": {
+ "type": "BlockStatement",
+ "start": 279,
+ "end": 1135,
+ "loc": {
+ "start": {
+ "line": 15,
+ "column": 25
+ },
+ "end": {
+ "line": 49,
+ "column": 1
+ }
+ },
+ "body": [
+ {
+ "type": "VariableDeclaration",
+ "start": 284,
+ "end": 313,
+ "loc": {
+ "start": {
+ "line": 17,
+ "column": 2
+ },
+ "end": {
+ "line": 17,
+ "column": 31
+ }
+ },
+ "declarations": [
+ {
+ "type": "VariableDeclarator",
+ "start": 288,
+ "end": 312,
+ "loc": {
+ "start": {
+ "line": 17,
+ "column": 6
+ },
+ "end": {
+ "line": 17,
+ "column": 30
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 288,
+ "end": 305,
+ "loc": {
+ "start": {
+ "line": 17,
+ "column": 6
+ },
+ "end": {
+ "line": 17,
+ "column": 23
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ },
+ "init": {
+ "type": "NullLiteral",
+ "start": 308,
+ "end": 312,
+ "loc": {
+ "start": {
+ "line": 17,
+ "column": 26
+ },
+ "end": {
+ "line": 17,
+ "column": 30
+ }
+ }
+ }
+ }
+ ],
+ "kind": "let"
+ },
+ {
+ "type": "TryStatement",
+ "start": 317,
+ "end": 1103,
+ "loc": {
+ "start": {
+ "line": 19,
+ "column": 2
+ },
+ "end": {
+ "line": 45,
+ "column": 3
+ }
+ },
+ "block": {
+ "type": "BlockStatement",
+ "start": 320,
+ "end": 590,
+ "loc": {
+ "start": {
+ "line": 19,
+ "column": 5
+ },
+ "end": {
+ "line": 27,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "VariableDeclaration",
+ "start": 444,
+ "end": 494,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 4
+ },
+ "end": {
+ "line": 25,
+ "column": 54
+ }
+ },
+ "declarations": [
+ {
+ "type": "VariableDeclarator",
+ "start": 448,
+ "end": 493,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 8
+ },
+ "end": {
+ "line": 25,
+ "column": 53
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 448,
+ "end": 468,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 8
+ },
+ "end": {
+ "line": 25,
+ "column": 28
+ },
+ "identifierName": "currentScriptElement"
+ },
+ "name": "currentScriptElement",
+ "leadingComments": null
+ },
+ "init": {
+ "type": "MemberExpression",
+ "start": 471,
+ "end": 493,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 31
+ },
+ "end": {
+ "line": 25,
+ "column": 53
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 471,
+ "end": 479,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 31
+ },
+ "end": {
+ "line": 25,
+ "column": 39
+ },
+ "identifierName": "document"
+ },
+ "name": "document"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 480,
+ "end": 493,
+ "loc": {
+ "start": {
+ "line": 25,
+ "column": 40
+ },
+ "end": {
+ "line": 25,
+ "column": 53
+ },
+ "identifierName": "currentScript"
+ },
+ "name": "currentScript"
+ },
+ "computed": false
+ },
+ "leadingComments": null
+ }
+ ],
+ "kind": "let",
+ "leadingComments": [
+ {
+ "type": "CommentLine",
+ "value": " FF, Chrome",
+ "start": 326,
+ "end": 339,
+ "loc": {
+ "start": {
+ "line": 20,
+ "column": 4
+ },
+ "end": {
+ "line": 20,
+ "column": 17
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " use their API to get the path of current script",
+ "start": 344,
+ "end": 394,
+ "loc": {
+ "start": {
+ "line": 21,
+ "column": 4
+ },
+ "end": {
+ "line": 21,
+ "column": 54
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " a.b();",
+ "start": 400,
+ "end": 409,
+ "loc": {
+ "start": {
+ "line": 23,
+ "column": 4
+ },
+ "end": {
+ "line": 23,
+ "column": 13
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " console.log('Stage1');",
+ "start": 414,
+ "end": 439,
+ "loc": {
+ "start": {
+ "line": 24,
+ "column": 4
+ },
+ "end": {
+ "line": 24,
+ "column": 29
+ }
+ }
+ }
+ ]
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 499,
+ "end": 586,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 4
+ },
+ "end": {
+ "line": 26,
+ "column": 91
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 499,
+ "end": 585,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 4
+ },
+ "end": {
+ "line": 26,
+ "column": 90
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 499,
+ "end": 516,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 4
+ },
+ "end": {
+ "line": 26,
+ "column": 21
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ },
+ "right": {
+ "type": "CallExpression",
+ "start": 519,
+ "end": 585,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 24
+ },
+ "end": {
+ "line": 26,
+ "column": 90
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 519,
+ "end": 567,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 24
+ },
+ "end": {
+ "line": 26,
+ "column": 72
+ }
+ },
+ "object": {
+ "type": "CallExpression",
+ "start": 519,
+ "end": 559,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 24
+ },
+ "end": {
+ "line": 26,
+ "column": 64
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 519,
+ "end": 552,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 24
+ },
+ "end": {
+ "line": 26,
+ "column": 57
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 519,
+ "end": 539,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 24
+ },
+ "end": {
+ "line": 26,
+ "column": 44
+ },
+ "identifierName": "currentScriptElement"
+ },
+ "name": "currentScriptElement"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 540,
+ "end": 552,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 45
+ },
+ "end": {
+ "line": 26,
+ "column": 57
+ },
+ "identifierName": "getAttribute"
+ },
+ "name": "getAttribute"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "StringLiteral",
+ "start": 553,
+ "end": 558,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 58
+ },
+ "end": {
+ "line": 26,
+ "column": 63
+ }
+ },
+ "extra": {
+ "rawValue": "src",
+ "raw": "'src'"
+ },
+ "value": "src"
+ }
+ ]
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 560,
+ "end": 567,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 65
+ },
+ "end": {
+ "line": 26,
+ "column": 72
+ },
+ "identifierName": "replace"
+ },
+ "name": "replace"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "RegExpLiteral",
+ "start": 568,
+ "end": 580,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 73
+ },
+ "end": {
+ "line": 26,
+ "column": 85
+ }
+ },
+ "extra": {
+ "raw": "/[^/\\\\\\\\]+$/"
+ },
+ "pattern": "[^/\\\\\\\\]+$",
+ "flags": ""
+ },
+ {
+ "type": "StringLiteral",
+ "start": 582,
+ "end": 584,
+ "loc": {
+ "start": {
+ "line": 26,
+ "column": 87
+ },
+ "end": {
+ "line": 26,
+ "column": 89
+ }
+ },
+ "extra": {
+ "rawValue": "",
+ "raw": "''"
+ },
+ "value": ""
+ }
+ ]
+ }
+ }
+ }
+ ],
+ "directives": []
+ },
+ "handler": {
+ "type": "CatchClause",
+ "start": 590,
+ "end": 1103,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 3
+ },
+ "end": {
+ "line": 45,
+ "column": 3
+ }
+ },
+ "param": {
+ "type": "Identifier",
+ "start": 596,
+ "end": 597,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 9
+ },
+ "end": {
+ "line": 27,
+ "column": 10
+ },
+ "identifierName": "e"
+ },
+ "name": "e"
+ },
+ "body": {
+ "type": "BlockStatement",
+ "start": 598,
+ "end": 1103,
+ "loc": {
+ "start": {
+ "line": 27,
+ "column": 11
+ },
+ "end": {
+ "line": 45,
+ "column": 3
+ }
+ },
+ "body": [
+ {
+ "type": "VariableDeclaration",
+ "start": 694,
+ "end": 797,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 4
+ },
+ "end": {
+ "line": 34,
+ "column": 51
+ }
+ },
+ "declarations": [
+ {
+ "type": "VariableDeclarator",
+ "start": 698,
+ "end": 744,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 8
+ },
+ "end": {
+ "line": 33,
+ "column": 54
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 698,
+ "end": 703,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 8
+ },
+ "end": {
+ "line": 33,
+ "column": 13
+ },
+ "identifierName": "stack"
+ },
+ "name": "stack",
+ "leadingComments": null
+ },
+ "init": {
+ "type": "LogicalExpression",
+ "start": 706,
+ "end": 744,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 16
+ },
+ "end": {
+ "line": 33,
+ "column": 54
+ }
+ },
+ "left": {
+ "type": "LogicalExpression",
+ "start": 706,
+ "end": 728,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 16
+ },
+ "end": {
+ "line": 33,
+ "column": 38
+ }
+ },
+ "left": {
+ "type": "MemberExpression",
+ "start": 706,
+ "end": 713,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 16
+ },
+ "end": {
+ "line": 33,
+ "column": 23
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 706,
+ "end": 707,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 16
+ },
+ "end": {
+ "line": 33,
+ "column": 17
+ },
+ "identifierName": "e"
+ },
+ "name": "e"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 708,
+ "end": 713,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 18
+ },
+ "end": {
+ "line": 33,
+ "column": 23
+ },
+ "identifierName": "stack"
+ },
+ "name": "stack"
+ },
+ "computed": false
+ },
+ "operator": "||",
+ "right": {
+ "type": "MemberExpression",
+ "start": 717,
+ "end": 728,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 27
+ },
+ "end": {
+ "line": 33,
+ "column": 38
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 717,
+ "end": 718,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 27
+ },
+ "end": {
+ "line": 33,
+ "column": 28
+ },
+ "identifierName": "e"
+ },
+ "name": "e"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 719,
+ "end": 728,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 29
+ },
+ "end": {
+ "line": 33,
+ "column": 38
+ },
+ "identifierName": "sourceURL"
+ },
+ "name": "sourceURL"
+ },
+ "computed": false
+ }
+ },
+ "operator": "||",
+ "right": {
+ "type": "MemberExpression",
+ "start": 732,
+ "end": 744,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 42
+ },
+ "end": {
+ "line": 33,
+ "column": 54
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 732,
+ "end": 733,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 42
+ },
+ "end": {
+ "line": 33,
+ "column": 43
+ },
+ "identifierName": "e"
+ },
+ "name": "e"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 734,
+ "end": 744,
+ "loc": {
+ "start": {
+ "line": 33,
+ "column": 44
+ },
+ "end": {
+ "line": 33,
+ "column": 54
+ },
+ "identifierName": "stacktrace"
+ },
+ "name": "stacktrace"
+ },
+ "computed": false
+ }
+ },
+ "leadingComments": null
+ },
+ {
+ "type": "VariableDeclarator",
+ "start": 750,
+ "end": 796,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 4
+ },
+ "end": {
+ "line": 34,
+ "column": 50
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 750,
+ "end": 761,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 4
+ },
+ "end": {
+ "line": 34,
+ "column": 15
+ },
+ "identifierName": "rExtractUri"
+ },
+ "name": "rExtractUri"
+ },
+ "init": {
+ "type": "RegExpLiteral",
+ "start": 764,
+ "end": 796,
+ "loc": {
+ "start": {
+ "line": 34,
+ "column": 18
+ },
+ "end": {
+ "line": 34,
+ "column": 50
+ }
+ },
+ "extra": {
+ "raw": "/(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\//"
+ },
+ "pattern": "(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\/",
+ "flags": ""
+ }
+ }
+ ],
+ "kind": "let",
+ "leadingComments": [
+ {
+ "type": "CommentLine",
+ "value": " IE 10 +, Safari and Opera 9",
+ "start": 604,
+ "end": 634,
+ "loc": {
+ "start": {
+ "line": 28,
+ "column": 4
+ },
+ "end": {
+ "line": 28,
+ "column": 34
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " console.log('Stage2');",
+ "start": 640,
+ "end": 665,
+ "loc": {
+ "start": {
+ "line": 30,
+ "column": 4
+ },
+ "end": {
+ "line": 30,
+ "column": 29
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " console.log(e);",
+ "start": 670,
+ "end": 688,
+ "loc": {
+ "start": {
+ "line": 31,
+ "column": 4
+ },
+ "end": {
+ "line": 31,
+ "column": 22
+ }
+ }
+ }
+ ],
+ "trailingComments": [
+ {
+ "type": "CommentLine",
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 42
+ }
+ }
+ }
+ ]
+ },
+ {
+ "type": "VariableDeclaration",
+ "start": 845,
+ "end": 883,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 4
+ },
+ "end": {
+ "line": 36,
+ "column": 42
+ }
+ },
+ "declarations": [
+ {
+ "type": "VariableDeclarator",
+ "start": 849,
+ "end": 882,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 8
+ },
+ "end": {
+ "line": 36,
+ "column": 41
+ }
+ },
+ "id": {
+ "type": "Identifier",
+ "start": 849,
+ "end": 856,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 8
+ },
+ "end": {
+ "line": 36,
+ "column": 15
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath",
+ "leadingComments": null
+ },
+ "init": {
+ "type": "CallExpression",
+ "start": 859,
+ "end": 882,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 18
+ },
+ "end": {
+ "line": 36,
+ "column": 41
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 859,
+ "end": 875,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 18
+ },
+ "end": {
+ "line": 36,
+ "column": 34
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 859,
+ "end": 870,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 18
+ },
+ "end": {
+ "line": 36,
+ "column": 29
+ },
+ "identifierName": "rExtractUri"
+ },
+ "name": "rExtractUri"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 871,
+ "end": 875,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 30
+ },
+ "end": {
+ "line": 36,
+ "column": 34
+ },
+ "identifierName": "exec"
+ },
+ "name": "exec"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 876,
+ "end": 881,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 35
+ },
+ "end": {
+ "line": 36,
+ "column": 40
+ },
+ "identifierName": "stack"
+ },
+ "name": "stack"
+ }
+ ]
+ },
+ "leadingComments": null
+ }
+ ],
+ "kind": "let",
+ "leadingComments": [
+ {
+ "type": "CommentLine",
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 42
+ }
+ }
+ }
+ ]
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 888,
+ "end": 919,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 4
+ },
+ "end": {
+ "line": 37,
+ "column": 35
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 888,
+ "end": 918,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 4
+ },
+ "end": {
+ "line": 37,
+ "column": 34
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 888,
+ "end": 905,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 4
+ },
+ "end": {
+ "line": 37,
+ "column": 21
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ },
+ "right": {
+ "type": "MemberExpression",
+ "start": 908,
+ "end": 918,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 24
+ },
+ "end": {
+ "line": 37,
+ "column": 34
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 908,
+ "end": 915,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 24
+ },
+ "end": {
+ "line": 37,
+ "column": 31
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath"
+ },
+ "property": {
+ "type": "NumericLiteral",
+ "start": 916,
+ "end": 917,
+ "loc": {
+ "start": {
+ "line": 37,
+ "column": 32
+ },
+ "end": {
+ "line": 37,
+ "column": 33
+ }
+ },
+ "extra": {
+ "rawValue": 0,
+ "raw": "0"
+ },
+ "value": 0
+ },
+ "computed": true
+ }
+ }
+ },
+ {
+ "type": "IfStatement",
+ "start": 925,
+ "end": 1098,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 4
+ },
+ "end": {
+ "line": 43,
+ "column": 5
+ }
+ },
+ "test": {
+ "type": "BinaryExpression",
+ "start": 928,
+ "end": 952,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 7
+ },
+ "end": {
+ "line": 39,
+ "column": 31
+ }
+ },
+ "left": {
+ "type": "Identifier",
+ "start": 928,
+ "end": 945,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 7
+ },
+ "end": {
+ "line": 39,
+ "column": 24
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ },
+ "operator": "===",
+ "right": {
+ "type": "StringLiteral",
+ "start": 950,
+ "end": 952,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 29
+ },
+ "end": {
+ "line": 39,
+ "column": 31
+ }
+ },
+ "extra": {
+ "rawValue": "",
+ "raw": "''"
+ },
+ "value": ""
+ }
+ },
+ "consequent": {
+ "type": "BlockStatement",
+ "start": 953,
+ "end": 1098,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 32
+ },
+ "end": {
+ "line": 43,
+ "column": 5
+ }
+ },
+ "body": [
+ {
+ "type": "ExpressionStatement",
+ "start": 961,
+ "end": 1013,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 6
+ },
+ "end": {
+ "line": 40,
+ "column": 58
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 961,
+ "end": 1012,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 6
+ },
+ "end": {
+ "line": 40,
+ "column": 57
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 961,
+ "end": 972,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 6
+ },
+ "end": {
+ "line": 40,
+ "column": 17
+ },
+ "identifierName": "rExtractUri"
+ },
+ "name": "rExtractUri"
+ },
+ "right": {
+ "type": "RegExpLiteral",
+ "start": 975,
+ "end": 1012,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 20
+ },
+ "end": {
+ "line": 40,
+ "column": 57
+ }
+ },
+ "extra": {
+ "raw": "/(?:http|https|file):\\/\\/.*?\\/.+?.js/"
+ },
+ "pattern": "(?:http|https|file):\\/\\/.*?\\/.+?.js",
+ "flags": ""
+ }
+ }
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 1020,
+ "end": 1054,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 6
+ },
+ "end": {
+ "line": 41,
+ "column": 40
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 1020,
+ "end": 1053,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 6
+ },
+ "end": {
+ "line": 41,
+ "column": 39
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 1020,
+ "end": 1027,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 6
+ },
+ "end": {
+ "line": 41,
+ "column": 13
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath"
+ },
+ "right": {
+ "type": "CallExpression",
+ "start": 1030,
+ "end": 1053,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 39
+ }
+ },
+ "callee": {
+ "type": "MemberExpression",
+ "start": 1030,
+ "end": 1046,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 32
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 1030,
+ "end": 1041,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 16
+ },
+ "end": {
+ "line": 41,
+ "column": 27
+ },
+ "identifierName": "rExtractUri"
+ },
+ "name": "rExtractUri"
+ },
+ "property": {
+ "type": "Identifier",
+ "start": 1042,
+ "end": 1046,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 28
+ },
+ "end": {
+ "line": 41,
+ "column": 32
+ },
+ "identifierName": "exec"
+ },
+ "name": "exec"
+ },
+ "computed": false
+ },
+ "arguments": [
+ {
+ "type": "Identifier",
+ "start": 1047,
+ "end": 1052,
+ "loc": {
+ "start": {
+ "line": 41,
+ "column": 33
+ },
+ "end": {
+ "line": 41,
+ "column": 38
+ },
+ "identifierName": "stack"
+ },
+ "name": "stack"
+ }
+ ]
+ }
+ }
+ },
+ {
+ "type": "ExpressionStatement",
+ "start": 1061,
+ "end": 1092,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 6
+ },
+ "end": {
+ "line": 42,
+ "column": 37
+ }
+ },
+ "expression": {
+ "type": "AssignmentExpression",
+ "start": 1061,
+ "end": 1091,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 6
+ },
+ "end": {
+ "line": 42,
+ "column": 36
+ }
+ },
+ "operator": "=",
+ "left": {
+ "type": "Identifier",
+ "start": 1061,
+ "end": 1078,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 6
+ },
+ "end": {
+ "line": 42,
+ "column": 23
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ },
+ "right": {
+ "type": "MemberExpression",
+ "start": 1081,
+ "end": 1091,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 26
+ },
+ "end": {
+ "line": 42,
+ "column": 36
+ }
+ },
+ "object": {
+ "type": "Identifier",
+ "start": 1081,
+ "end": 1088,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 26
+ },
+ "end": {
+ "line": 42,
+ "column": 33
+ },
+ "identifierName": "absPath"
+ },
+ "name": "absPath"
+ },
+ "property": {
+ "type": "NumericLiteral",
+ "start": 1089,
+ "end": 1090,
+ "loc": {
+ "start": {
+ "line": 42,
+ "column": 34
+ },
+ "end": {
+ "line": 42,
+ "column": 35
+ }
+ },
+ "extra": {
+ "rawValue": 0,
+ "raw": "0"
+ },
+ "value": 0
+ },
+ "computed": true
+ }
+ }
+ }
+ ],
+ "directives": []
+ },
+ "alternate": null
}
- ]
+ ],
+ "directives": []
}
- ]
+ },
+ "guardedHandlers": [],
+ "finalizer": null
+ },
+ {
+ "type": "ReturnStatement",
+ "start": 1107,
+ "end": 1132,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 2
+ },
+ "end": {
+ "line": 47,
+ "column": 27
+ }
+ },
+ "argument": {
+ "type": "Identifier",
+ "start": 1114,
+ "end": 1131,
+ "loc": {
+ "start": {
+ "line": 47,
+ "column": 9
+ },
+ "end": {
+ "line": 47,
+ "column": 26
+ },
+ "identifierName": "currentScriptPath"
+ },
+ "name": "currentScriptPath"
+ }
+ }
+ ],
+ "directives": [],
+ "trailingComments": null
+ },
+ "leadingComments": [
+ {
+ "type": "CommentBlock",
+ "value": "*\n * Get current script path\n * @return {String} The accessable path of current script\n * @example\n * get 'dev/' or 'https://www.host.com/test/js/'\n ",
+ "start": 99,
+ "end": 252,
+ "loc": {
+ "start": {
+ "line": 8,
+ "column": 0
+ },
+ "end": {
+ "line": 13,
+ "column": 3
+ }
}
}
],
- "directives": []
+ "trailingComments": [
+ {
+ "type": "CommentLine",
+ "value": " expose the path to the global,",
+ "start": 1137,
+ "end": 1170,
+ "loc": {
+ "start": {
+ "line": 51,
+ "column": 0
+ },
+ "end": {
+ "line": 51,
+ "column": 33
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " and wp will finish the following work",
+ "start": 1171,
+ "end": 1211,
+ "loc": {
+ "start": {
+ "line": 52,
+ "column": 0
+ },
+ "end": {
+ "line": 52,
+ "column": 40
+ }
+ }
+ }
+ ]
},
- "alternate": null
+ "specifiers": null,
+ "source": null,
+ "leadingComments": null
}
],
"directives": [
{
"type": "Directive",
- "start": 70,
- "end": 83,
+ "start": 84,
+ "end": 97,
"loc": {
"start": {
"line": 6,
@@ -1985,8 +3871,8 @@
},
"value": {
"type": "DirectiveLiteral",
- "start": 70,
- "end": 82,
+ "start": 84,
+ "end": 96,
"loc": {
"start": {
"line": 6,
@@ -2002,14 +3888,15 @@
"raw": "'use strict'",
"rawValue": "use strict"
},
- "leadingComments": null
+ "leadingComments": null,
+ "trailingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
- "value": "*\n * @description Automatic locate the publicPath for webpack\n ",
+ "value": "*\n * @description Automatic locate the publicPath and set it up for webpack\n ",
"start": 0,
- "end": 67,
+ "end": 81,
"loc": {
"start": {
"line": 1,
@@ -2021,6 +3908,24 @@
}
}
}
+ ],
+ "trailingComments": [
+ {
+ "type": "CommentBlock",
+ "value": "*\n * Get current script path\n * @return {String} The accessable path of current script\n * @example\n * get 'dev/' or 'https://www.host.com/test/js/'\n ",
+ "start": 99,
+ "end": 252,
+ "loc": {
+ "start": {
+ "line": 8,
+ "column": 0
+ },
+ "end": {
+ "line": 13,
+ "column": 3
+ }
+ }
+ }
]
}
]
@@ -2028,9 +3933,9 @@
"comments": [
{
"type": "CommentBlock",
- "value": "*\n * @description Automatic locate the publicPath for webpack\n ",
+ "value": "*\n * @description Automatic locate the publicPath and set it up for webpack\n ",
"start": 0,
- "end": 67,
+ "end": 81,
"loc": {
"start": {
"line": 1,
@@ -2042,18 +3947,34 @@
}
}
},
+ {
+ "type": "CommentBlock",
+ "value": "*\n * Get current script path\n * @return {String} The accessable path of current script\n * @example\n * get 'dev/' or 'https://www.host.com/test/js/'\n ",
+ "start": 99,
+ "end": 252,
+ "loc": {
+ "start": {
+ "line": 8,
+ "column": 0
+ },
+ "end": {
+ "line": 13,
+ "column": 3
+ }
+ }
+ },
{
"type": "CommentLine",
"value": " FF, Chrome",
- "start": 157,
- "end": 170,
+ "start": 326,
+ "end": 339,
"loc": {
"start": {
- "line": 13,
+ "line": 20,
"column": 4
},
"end": {
- "line": 13,
+ "line": 20,
"column": 17
}
}
@@ -2061,15 +3982,15 @@
{
"type": "CommentLine",
"value": " use their API to get the path of current script",
- "start": 175,
- "end": 225,
+ "start": 344,
+ "end": 394,
"loc": {
"start": {
- "line": 14,
+ "line": 21,
"column": 4
},
"end": {
- "line": 14,
+ "line": 21,
"column": 54
}
}
@@ -2077,15 +3998,15 @@
{
"type": "CommentLine",
"value": " a.b();",
- "start": 231,
- "end": 240,
+ "start": 400,
+ "end": 409,
"loc": {
"start": {
- "line": 16,
+ "line": 23,
"column": 4
},
"end": {
- "line": 16,
+ "line": 23,
"column": 13
}
}
@@ -2093,15 +4014,15 @@
{
"type": "CommentLine",
"value": " console.log('Stage1');",
- "start": 245,
- "end": 270,
+ "start": 414,
+ "end": 439,
"loc": {
"start": {
- "line": 17,
+ "line": 24,
"column": 4
},
"end": {
- "line": 17,
+ "line": 24,
"column": 29
}
}
@@ -2109,15 +4030,15 @@
{
"type": "CommentLine",
"value": " IE 10 +, Safari and Opera 9",
- "start": 435,
- "end": 465,
+ "start": 604,
+ "end": 634,
"loc": {
"start": {
- "line": 21,
+ "line": 28,
"column": 4
},
"end": {
- "line": 21,
+ "line": 28,
"column": 34
}
}
@@ -2125,31 +4046,63 @@
{
"type": "CommentLine",
"value": " console.log('Stage2');",
- "start": 471,
- "end": 496,
+ "start": 640,
+ "end": 665,
"loc": {
"start": {
- "line": 23,
+ "line": 30,
"column": 4
},
"end": {
- "line": 23,
+ "line": 30,
"column": 29
}
}
},
+ {
+ "type": "CommentLine",
+ "value": " console.log(e);",
+ "start": 670,
+ "end": 688,
+ "loc": {
+ "start": {
+ "line": 31,
+ "column": 4
+ },
+ "end": {
+ "line": 31,
+ "column": 22
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 42
+ }
+ }
+ },
{
"type": "CommentLine",
"value": " expose the path to the global,",
- "start": 896,
- "end": 929,
+ "start": 1137,
+ "end": 1170,
"loc": {
"start": {
- "line": 39,
+ "line": 51,
"column": 0
},
"end": {
- "line": 39,
+ "line": 51,
"column": 33
}
}
@@ -2157,15 +4110,15 @@
{
"type": "CommentLine",
"value": " and wp will finish the following work",
- "start": 930,
- "end": 970,
+ "start": 1171,
+ "end": 1211,
"loc": {
"start": {
- "line": 40,
+ "line": 52,
"column": 0
},
"end": {
- "line": 40,
+ "line": 52,
"column": 40
}
}
@@ -2174,9 +4127,9 @@
"tokens": [
{
"type": "CommentBlock",
- "value": "*\n * @description Automatic locate the publicPath for webpack\n ",
+ "value": "*\n * @description Automatic locate the publicPath and set it up for webpack\n ",
"start": 0,
- "end": 67,
+ "end": 81,
"loc": {
"start": {
"line": 1,
@@ -2202,8 +4155,8 @@
"updateContext": null
},
"value": "use strict",
- "start": 70,
- "end": 82,
+ "start": 84,
+ "end": 96,
"loc": {
"start": {
"line": 6,
@@ -2228,8 +4181,8 @@
"binop": null,
"updateContext": null
},
- "start": 82,
- "end": 83,
+ "start": 96,
+ "end": 97,
"loc": {
"start": {
"line": 6,
@@ -2241,6 +4194,22 @@
}
}
},
+ {
+ "type": "CommentBlock",
+ "value": "*\n * Get current script path\n * @return {String} The accessable path of current script\n * @example\n * get 'dev/' or 'https://www.host.com/test/js/'\n ",
+ "start": 99,
+ "end": 252,
+ "loc": {
+ "start": {
+ "line": 8,
+ "column": 0
+ },
+ "end": {
+ "line": 13,
+ "column": 3
+ }
+ }
+ },
{
"type": {
"label": "function",
@@ -2255,15 +4224,15 @@
"binop": null
},
"value": "function",
- "start": 85,
- "end": 93,
+ "start": 254,
+ "end": 262,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 0
},
"end": {
- "line": 8,
+ "line": 15,
"column": 8
}
}
@@ -2281,15 +4250,15 @@
"binop": null
},
"value": "getCurrentPath",
- "start": 94,
- "end": 108,
+ "start": 263,
+ "end": 277,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 9
},
"end": {
- "line": 8,
+ "line": 15,
"column": 23
}
}
@@ -2306,15 +4275,15 @@
"postfix": false,
"binop": null
},
- "start": 108,
- "end": 109,
+ "start": 277,
+ "end": 278,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 23
},
"end": {
- "line": 8,
+ "line": 15,
"column": 24
}
}
@@ -2331,15 +4300,15 @@
"postfix": false,
"binop": null
},
- "start": 109,
- "end": 110,
+ "start": 278,
+ "end": 279,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 24
},
"end": {
- "line": 8,
+ "line": 15,
"column": 25
}
}
@@ -2356,15 +4325,15 @@
"postfix": false,
"binop": null
},
- "start": 110,
- "end": 111,
+ "start": 279,
+ "end": 280,
"loc": {
"start": {
- "line": 8,
+ "line": 15,
"column": 25
},
"end": {
- "line": 8,
+ "line": 15,
"column": 26
}
}
@@ -2384,15 +4353,15 @@
"updateContext": null
},
"value": "let",
- "start": 115,
- "end": 118,
+ "start": 284,
+ "end": 287,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 2
},
"end": {
- "line": 10,
+ "line": 17,
"column": 5
}
}
@@ -2410,15 +4379,15 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 119,
- "end": 136,
+ "start": 288,
+ "end": 305,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 6
},
"end": {
- "line": 10,
+ "line": 17,
"column": 23
}
}
@@ -2437,15 +4406,15 @@
"updateContext": null
},
"value": "=",
- "start": 137,
- "end": 138,
+ "start": 306,
+ "end": 307,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 24
},
"end": {
- "line": 10,
+ "line": 17,
"column": 25
}
}
@@ -2465,15 +4434,15 @@
"updateContext": null
},
"value": "null",
- "start": 139,
- "end": 143,
+ "start": 308,
+ "end": 312,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 26
},
"end": {
- "line": 10,
+ "line": 17,
"column": 30
}
}
@@ -2491,15 +4460,15 @@
"binop": null,
"updateContext": null
},
- "start": 143,
- "end": 144,
+ "start": 312,
+ "end": 313,
"loc": {
"start": {
- "line": 10,
+ "line": 17,
"column": 30
},
"end": {
- "line": 10,
+ "line": 17,
"column": 31
}
}
@@ -2519,15 +4488,15 @@
"updateContext": null
},
"value": "try",
- "start": 148,
- "end": 151,
+ "start": 317,
+ "end": 320,
"loc": {
"start": {
- "line": 12,
+ "line": 19,
"column": 2
},
"end": {
- "line": 12,
+ "line": 19,
"column": 5
}
}
@@ -2544,15 +4513,15 @@
"postfix": false,
"binop": null
},
- "start": 151,
- "end": 152,
+ "start": 320,
+ "end": 321,
"loc": {
"start": {
- "line": 12,
+ "line": 19,
"column": 5
},
"end": {
- "line": 12,
+ "line": 19,
"column": 6
}
}
@@ -2560,15 +4529,15 @@
{
"type": "CommentLine",
"value": " FF, Chrome",
- "start": 157,
- "end": 170,
+ "start": 326,
+ "end": 339,
"loc": {
"start": {
- "line": 13,
+ "line": 20,
"column": 4
},
"end": {
- "line": 13,
+ "line": 20,
"column": 17
}
}
@@ -2576,15 +4545,15 @@
{
"type": "CommentLine",
"value": " use their API to get the path of current script",
- "start": 175,
- "end": 225,
+ "start": 344,
+ "end": 394,
"loc": {
"start": {
- "line": 14,
+ "line": 21,
"column": 4
},
"end": {
- "line": 14,
+ "line": 21,
"column": 54
}
}
@@ -2592,15 +4561,15 @@
{
"type": "CommentLine",
"value": " a.b();",
- "start": 231,
- "end": 240,
+ "start": 400,
+ "end": 409,
"loc": {
"start": {
- "line": 16,
+ "line": 23,
"column": 4
},
"end": {
- "line": 16,
+ "line": 23,
"column": 13
}
}
@@ -2608,15 +4577,15 @@
{
"type": "CommentLine",
"value": " console.log('Stage1');",
- "start": 245,
- "end": 270,
+ "start": 414,
+ "end": 439,
"loc": {
"start": {
- "line": 17,
+ "line": 24,
"column": 4
},
"end": {
- "line": 17,
+ "line": 24,
"column": 29
}
}
@@ -2636,15 +4605,15 @@
"updateContext": null
},
"value": "let",
- "start": 275,
- "end": 278,
+ "start": 444,
+ "end": 447,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 4
},
"end": {
- "line": 18,
+ "line": 25,
"column": 7
}
}
@@ -2662,15 +4631,15 @@
"binop": null
},
"value": "currentScriptElement",
- "start": 279,
- "end": 299,
+ "start": 448,
+ "end": 468,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 8
},
"end": {
- "line": 18,
+ "line": 25,
"column": 28
}
}
@@ -2689,15 +4658,15 @@
"updateContext": null
},
"value": "=",
- "start": 300,
- "end": 301,
+ "start": 469,
+ "end": 470,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 29
},
"end": {
- "line": 18,
+ "line": 25,
"column": 30
}
}
@@ -2715,15 +4684,15 @@
"binop": null
},
"value": "document",
- "start": 302,
- "end": 310,
+ "start": 471,
+ "end": 479,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 31
},
"end": {
- "line": 18,
+ "line": 25,
"column": 39
}
}
@@ -2741,15 +4710,15 @@
"binop": null,
"updateContext": null
},
- "start": 310,
- "end": 311,
+ "start": 479,
+ "end": 480,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 39
},
"end": {
- "line": 18,
+ "line": 25,
"column": 40
}
}
@@ -2767,15 +4736,15 @@
"binop": null
},
"value": "currentScript",
- "start": 311,
- "end": 324,
+ "start": 480,
+ "end": 493,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 40
},
"end": {
- "line": 18,
+ "line": 25,
"column": 53
}
}
@@ -2793,15 +4762,15 @@
"binop": null,
"updateContext": null
},
- "start": 324,
- "end": 325,
+ "start": 493,
+ "end": 494,
"loc": {
"start": {
- "line": 18,
+ "line": 25,
"column": 53
},
"end": {
- "line": 18,
+ "line": 25,
"column": 54
}
}
@@ -2819,15 +4788,15 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 330,
- "end": 347,
+ "start": 499,
+ "end": 516,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 4
},
"end": {
- "line": 19,
+ "line": 26,
"column": 21
}
}
@@ -2846,15 +4815,15 @@
"updateContext": null
},
"value": "=",
- "start": 348,
- "end": 349,
+ "start": 517,
+ "end": 518,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 22
},
"end": {
- "line": 19,
+ "line": 26,
"column": 23
}
}
@@ -2872,15 +4841,15 @@
"binop": null
},
"value": "currentScriptElement",
- "start": 350,
- "end": 370,
+ "start": 519,
+ "end": 539,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 24
},
"end": {
- "line": 19,
+ "line": 26,
"column": 44
}
}
@@ -2898,15 +4867,15 @@
"binop": null,
"updateContext": null
},
- "start": 370,
- "end": 371,
+ "start": 539,
+ "end": 540,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 44
},
"end": {
- "line": 19,
+ "line": 26,
"column": 45
}
}
@@ -2924,15 +4893,15 @@
"binop": null
},
"value": "getAttribute",
- "start": 371,
- "end": 383,
+ "start": 540,
+ "end": 552,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 45
},
"end": {
- "line": 19,
+ "line": 26,
"column": 57
}
}
@@ -2949,15 +4918,15 @@
"postfix": false,
"binop": null
},
- "start": 383,
- "end": 384,
+ "start": 552,
+ "end": 553,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 57
},
"end": {
- "line": 19,
+ "line": 26,
"column": 58
}
}
@@ -2976,15 +4945,15 @@
"updateContext": null
},
"value": "src",
- "start": 384,
- "end": 389,
+ "start": 553,
+ "end": 558,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 58
},
"end": {
- "line": 19,
+ "line": 26,
"column": 63
}
}
@@ -3001,15 +4970,15 @@
"postfix": false,
"binop": null
},
- "start": 389,
- "end": 390,
+ "start": 558,
+ "end": 559,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 63
},
"end": {
- "line": 19,
+ "line": 26,
"column": 64
}
}
@@ -3027,15 +4996,15 @@
"binop": null,
"updateContext": null
},
- "start": 390,
- "end": 391,
+ "start": 559,
+ "end": 560,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 64
},
"end": {
- "line": 19,
+ "line": 26,
"column": 65
}
}
@@ -3053,15 +5022,15 @@
"binop": null
},
"value": "replace",
- "start": 391,
- "end": 398,
+ "start": 560,
+ "end": 567,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 65
},
"end": {
- "line": 19,
+ "line": 26,
"column": 72
}
}
@@ -3078,15 +5047,15 @@
"postfix": false,
"binop": null
},
- "start": 398,
- "end": 399,
+ "start": 567,
+ "end": 568,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 72
},
"end": {
- "line": 19,
+ "line": 26,
"column": 73
}
}
@@ -3108,15 +5077,15 @@
"pattern": "[^/\\\\\\\\]+$",
"flags": ""
},
- "start": 399,
- "end": 411,
+ "start": 568,
+ "end": 580,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 73
},
"end": {
- "line": 19,
+ "line": 26,
"column": 85
}
}
@@ -3134,15 +5103,15 @@
"binop": null,
"updateContext": null
},
- "start": 411,
- "end": 412,
+ "start": 580,
+ "end": 581,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 85
},
"end": {
- "line": 19,
+ "line": 26,
"column": 86
}
}
@@ -3161,15 +5130,15 @@
"updateContext": null
},
"value": "",
- "start": 413,
- "end": 415,
+ "start": 582,
+ "end": 584,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 87
},
"end": {
- "line": 19,
+ "line": 26,
"column": 89
}
}
@@ -3186,15 +5155,15 @@
"postfix": false,
"binop": null
},
- "start": 415,
- "end": 416,
+ "start": 584,
+ "end": 585,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 89
},
"end": {
- "line": 19,
+ "line": 26,
"column": 90
}
}
@@ -3212,15 +5181,15 @@
"binop": null,
"updateContext": null
},
- "start": 416,
- "end": 417,
+ "start": 585,
+ "end": 586,
"loc": {
"start": {
- "line": 19,
+ "line": 26,
"column": 90
},
"end": {
- "line": 19,
+ "line": 26,
"column": 91
}
}
@@ -3237,15 +5206,15 @@
"postfix": false,
"binop": null
},
- "start": 420,
- "end": 421,
+ "start": 589,
+ "end": 590,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 2
},
"end": {
- "line": 20,
+ "line": 27,
"column": 3
}
}
@@ -3265,15 +5234,15 @@
"updateContext": null
},
"value": "catch",
- "start": 421,
- "end": 426,
+ "start": 590,
+ "end": 595,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 3
},
"end": {
- "line": 20,
+ "line": 27,
"column": 8
}
}
@@ -3290,15 +5259,15 @@
"postfix": false,
"binop": null
},
- "start": 426,
- "end": 427,
+ "start": 595,
+ "end": 596,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 8
},
"end": {
- "line": 20,
+ "line": 27,
"column": 9
}
}
@@ -3316,15 +5285,15 @@
"binop": null
},
"value": "e",
- "start": 427,
- "end": 428,
+ "start": 596,
+ "end": 597,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 9
},
"end": {
- "line": 20,
+ "line": 27,
"column": 10
}
}
@@ -3341,15 +5310,15 @@
"postfix": false,
"binop": null
},
- "start": 428,
- "end": 429,
+ "start": 597,
+ "end": 598,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 10
},
"end": {
- "line": 20,
+ "line": 27,
"column": 11
}
}
@@ -3366,15 +5335,15 @@
"postfix": false,
"binop": null
},
- "start": 429,
- "end": 430,
+ "start": 598,
+ "end": 599,
"loc": {
"start": {
- "line": 20,
+ "line": 27,
"column": 11
},
"end": {
- "line": 20,
+ "line": 27,
"column": 12
}
}
@@ -3382,15 +5351,15 @@
{
"type": "CommentLine",
"value": " IE 10 +, Safari and Opera 9",
- "start": 435,
- "end": 465,
+ "start": 604,
+ "end": 634,
"loc": {
"start": {
- "line": 21,
+ "line": 28,
"column": 4
},
"end": {
- "line": 21,
+ "line": 28,
"column": 34
}
}
@@ -3398,19 +5367,35 @@
{
"type": "CommentLine",
"value": " console.log('Stage2');",
- "start": 471,
- "end": 496,
+ "start": 640,
+ "end": 665,
"loc": {
"start": {
- "line": 23,
+ "line": 30,
"column": 4
},
"end": {
- "line": 23,
+ "line": 30,
"column": 29
}
}
},
+ {
+ "type": "CommentLine",
+ "value": " console.log(e);",
+ "start": 670,
+ "end": 688,
+ "loc": {
+ "start": {
+ "line": 31,
+ "column": 4
+ },
+ "end": {
+ "line": 31,
+ "column": 22
+ }
+ }
+ },
{
"type": {
"label": "let",
@@ -3426,15 +5411,15 @@
"updateContext": null
},
"value": "let",
- "start": 501,
- "end": 504,
+ "start": 694,
+ "end": 697,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 4
},
"end": {
- "line": 24,
+ "line": 33,
"column": 7
}
}
@@ -3452,15 +5437,15 @@
"binop": null
},
"value": "stack",
- "start": 505,
- "end": 510,
+ "start": 698,
+ "end": 703,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 8
},
"end": {
- "line": 24,
+ "line": 33,
"column": 13
}
}
@@ -3479,15 +5464,15 @@
"updateContext": null
},
"value": "=",
- "start": 511,
- "end": 512,
+ "start": 704,
+ "end": 705,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 14
},
"end": {
- "line": 24,
+ "line": 33,
"column": 15
}
}
@@ -3505,15 +5490,15 @@
"binop": null
},
"value": "e",
- "start": 513,
- "end": 514,
+ "start": 706,
+ "end": 707,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 16
},
"end": {
- "line": 24,
+ "line": 33,
"column": 17
}
}
@@ -3531,15 +5516,15 @@
"binop": null,
"updateContext": null
},
- "start": 514,
- "end": 515,
+ "start": 707,
+ "end": 708,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 17
},
"end": {
- "line": 24,
+ "line": 33,
"column": 18
}
}
@@ -3557,15 +5542,15 @@
"binop": null
},
"value": "stack",
- "start": 515,
- "end": 520,
+ "start": 708,
+ "end": 713,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 18
},
"end": {
- "line": 24,
+ "line": 33,
"column": 23
}
}
@@ -3584,15 +5569,15 @@
"updateContext": null
},
"value": "||",
- "start": 521,
- "end": 523,
+ "start": 714,
+ "end": 716,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 24
},
"end": {
- "line": 24,
+ "line": 33,
"column": 26
}
}
@@ -3610,15 +5595,15 @@
"binop": null
},
"value": "e",
- "start": 524,
- "end": 525,
+ "start": 717,
+ "end": 718,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 27
},
"end": {
- "line": 24,
+ "line": 33,
"column": 28
}
}
@@ -3636,15 +5621,15 @@
"binop": null,
"updateContext": null
},
- "start": 525,
- "end": 526,
+ "start": 718,
+ "end": 719,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 28
},
"end": {
- "line": 24,
+ "line": 33,
"column": 29
}
}
@@ -3662,15 +5647,15 @@
"binop": null
},
"value": "sourceURL",
- "start": 526,
- "end": 535,
+ "start": 719,
+ "end": 728,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 29
},
"end": {
- "line": 24,
+ "line": 33,
"column": 38
}
}
@@ -3689,15 +5674,15 @@
"updateContext": null
},
"value": "||",
- "start": 536,
- "end": 538,
+ "start": 729,
+ "end": 731,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 39
},
"end": {
- "line": 24,
+ "line": 33,
"column": 41
}
}
@@ -3715,15 +5700,15 @@
"binop": null
},
"value": "e",
- "start": 539,
- "end": 540,
+ "start": 732,
+ "end": 733,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 42
},
"end": {
- "line": 24,
+ "line": 33,
"column": 43
}
}
@@ -3741,15 +5726,15 @@
"binop": null,
"updateContext": null
},
- "start": 540,
- "end": 541,
+ "start": 733,
+ "end": 734,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 43
},
"end": {
- "line": 24,
+ "line": 33,
"column": 44
}
}
@@ -3767,15 +5752,15 @@
"binop": null
},
"value": "stacktrace",
- "start": 541,
- "end": 551,
+ "start": 734,
+ "end": 744,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 44
},
"end": {
- "line": 24,
+ "line": 33,
"column": 54
}
}
@@ -3793,15 +5778,15 @@
"binop": null,
"updateContext": null
},
- "start": 551,
- "end": 552,
+ "start": 744,
+ "end": 745,
"loc": {
"start": {
- "line": 24,
+ "line": 33,
"column": 54
},
"end": {
- "line": 24,
+ "line": 33,
"column": 55
}
}
@@ -3819,15 +5804,15 @@
"binop": null
},
"value": "rExtractUri",
- "start": 557,
- "end": 568,
+ "start": 750,
+ "end": 761,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 4
},
"end": {
- "line": 25,
+ "line": 34,
"column": 15
}
}
@@ -3846,15 +5831,15 @@
"updateContext": null
},
"value": "=",
- "start": 569,
- "end": 570,
+ "start": 762,
+ "end": 763,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 16
},
"end": {
- "line": 25,
+ "line": 34,
"column": 17
}
}
@@ -3873,25 +5858,25 @@
"updateContext": null
},
"value": {
- "pattern": "(?:http|https|file):\\/\\/.*?\\/.+?.js",
+ "pattern": "(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\/",
"flags": ""
},
- "start": 571,
- "end": 608,
+ "start": 764,
+ "end": 796,
"loc": {
"start": {
- "line": 25,
+ "line": 34,
"column": 18
},
"end": {
- "line": 25,
- "column": 55
+ "line": 34,
+ "column": 50
}
}
},
{
"type": {
- "label": ",",
+ "label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
@@ -3902,16 +5887,60 @@
"binop": null,
"updateContext": null
},
- "start": 608,
- "end": 609,
+ "start": 796,
+ "end": 797,
"loc": {
"start": {
- "line": 25,
- "column": 55
+ "line": 34,
+ "column": 50
+ },
+ "end": {
+ "line": 34,
+ "column": 51
+ }
+ }
+ },
+ {
+ "type": "CommentLine",
+ "value": " TODO: Fix wrong RegExp: rExtractUri",
+ "start": 802,
+ "end": 840,
+ "loc": {
+ "start": {
+ "line": 35,
+ "column": 4
+ },
+ "end": {
+ "line": 35,
+ "column": 42
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "let",
+ "keyword": "let",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "value": "let",
+ "start": 845,
+ "end": 848,
+ "loc": {
+ "start": {
+ "line": 36,
+ "column": 4
},
"end": {
- "line": 25,
- "column": 56
+ "line": 36,
+ "column": 7
}
}
},
@@ -3928,16 +5957,16 @@
"binop": null
},
"value": "absPath",
- "start": 614,
- "end": 621,
+ "start": 849,
+ "end": 856,
"loc": {
"start": {
- "line": 26,
- "column": 4
+ "line": 36,
+ "column": 8
},
"end": {
- "line": 26,
- "column": 11
+ "line": 36,
+ "column": 15
}
}
},
@@ -3955,16 +5984,16 @@
"updateContext": null
},
"value": "=",
- "start": 622,
- "end": 623,
+ "start": 857,
+ "end": 858,
"loc": {
"start": {
- "line": 26,
- "column": 12
+ "line": 36,
+ "column": 16
},
"end": {
- "line": 26,
- "column": 13
+ "line": 36,
+ "column": 17
}
}
},
@@ -3981,16 +6010,16 @@
"binop": null
},
"value": "rExtractUri",
- "start": 624,
- "end": 635,
+ "start": 859,
+ "end": 870,
"loc": {
"start": {
- "line": 26,
- "column": 14
+ "line": 36,
+ "column": 18
},
"end": {
- "line": 26,
- "column": 25
+ "line": 36,
+ "column": 29
}
}
},
@@ -4007,16 +6036,16 @@
"binop": null,
"updateContext": null
},
- "start": 635,
- "end": 636,
+ "start": 870,
+ "end": 871,
"loc": {
"start": {
- "line": 26,
- "column": 25
+ "line": 36,
+ "column": 29
},
"end": {
- "line": 26,
- "column": 26
+ "line": 36,
+ "column": 30
}
}
},
@@ -4033,16 +6062,16 @@
"binop": null
},
"value": "exec",
- "start": 636,
- "end": 640,
+ "start": 871,
+ "end": 875,
"loc": {
"start": {
- "line": 26,
- "column": 26
+ "line": 36,
+ "column": 30
},
"end": {
- "line": 26,
- "column": 30
+ "line": 36,
+ "column": 34
}
}
},
@@ -4058,16 +6087,16 @@
"postfix": false,
"binop": null
},
- "start": 640,
- "end": 641,
+ "start": 875,
+ "end": 876,
"loc": {
"start": {
- "line": 26,
- "column": 30
+ "line": 36,
+ "column": 34
},
"end": {
- "line": 26,
- "column": 31
+ "line": 36,
+ "column": 35
}
}
},
@@ -4084,16 +6113,16 @@
"binop": null
},
"value": "stack",
- "start": 641,
- "end": 646,
+ "start": 876,
+ "end": 881,
"loc": {
"start": {
- "line": 26,
- "column": 31
+ "line": 36,
+ "column": 35
},
"end": {
- "line": 26,
- "column": 36
+ "line": 36,
+ "column": 40
}
}
},
@@ -4109,16 +6138,16 @@
"postfix": false,
"binop": null
},
- "start": 646,
- "end": 647,
+ "start": 881,
+ "end": 882,
"loc": {
"start": {
- "line": 26,
- "column": 36
+ "line": 36,
+ "column": 40
},
"end": {
- "line": 26,
- "column": 37
+ "line": 36,
+ "column": 41
}
}
},
@@ -4135,16 +6164,16 @@
"binop": null,
"updateContext": null
},
- "start": 647,
- "end": 648,
+ "start": 882,
+ "end": 883,
"loc": {
"start": {
- "line": 26,
- "column": 37
+ "line": 36,
+ "column": 41
},
"end": {
- "line": 26,
- "column": 38
+ "line": 36,
+ "column": 42
}
}
},
@@ -4161,15 +6190,15 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 653,
- "end": 670,
+ "start": 888,
+ "end": 905,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 4
},
"end": {
- "line": 27,
+ "line": 37,
"column": 21
}
}
@@ -4188,15 +6217,15 @@
"updateContext": null
},
"value": "=",
- "start": 671,
- "end": 672,
+ "start": 906,
+ "end": 907,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 22
},
"end": {
- "line": 27,
+ "line": 37,
"column": 23
}
}
@@ -4214,15 +6243,15 @@
"binop": null
},
"value": "absPath",
- "start": 673,
- "end": 680,
+ "start": 908,
+ "end": 915,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 24
},
"end": {
- "line": 27,
+ "line": 37,
"column": 31
}
}
@@ -4240,15 +6269,15 @@
"binop": null,
"updateContext": null
},
- "start": 680,
- "end": 681,
+ "start": 915,
+ "end": 916,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 31
},
"end": {
- "line": 27,
+ "line": 37,
"column": 32
}
}
@@ -4267,15 +6296,15 @@
"updateContext": null
},
"value": 0,
- "start": 681,
- "end": 682,
+ "start": 916,
+ "end": 917,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 32
},
"end": {
- "line": 27,
+ "line": 37,
"column": 33
}
}
@@ -4293,22 +6322,22 @@
"binop": null,
"updateContext": null
},
- "start": 682,
- "end": 683,
+ "start": 917,
+ "end": 918,
"loc": {
"start": {
- "line": 27,
+ "line": 37,
"column": 33
},
"end": {
- "line": 27,
+ "line": 37,
"column": 34
}
}
},
{
"type": {
- "label": "||",
+ "label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
@@ -4316,28 +6345,28 @@
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": 1,
+ "binop": null,
"updateContext": null
},
- "value": "||",
- "start": 684,
- "end": 686,
+ "start": 918,
+ "end": 919,
"loc": {
"start": {
- "line": 27,
- "column": 35
+ "line": 37,
+ "column": 34
},
"end": {
- "line": 27,
- "column": 37
+ "line": 37,
+ "column": 35
}
}
},
{
"type": {
- "label": "string",
+ "label": "if",
+ "keyword": "if",
"beforeExpr": false,
- "startsExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4346,43 +6375,42 @@
"binop": null,
"updateContext": null
},
- "value": "",
- "start": 687,
- "end": 689,
+ "value": "if",
+ "start": 925,
+ "end": 927,
"loc": {
"start": {
- "line": 27,
- "column": 38
+ "line": 39,
+ "column": 4
},
"end": {
- "line": 27,
- "column": 40
+ "line": 39,
+ "column": 6
}
}
},
{
"type": {
- "label": ";",
+ "label": "(",
"beforeExpr": true,
- "startsExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "start": 689,
- "end": 690,
+ "start": 927,
+ "end": 928,
"loc": {
"start": {
- "line": 27,
- "column": 40
+ "line": 39,
+ "column": 6
},
"end": {
- "line": 27,
- "column": 41
+ "line": 39,
+ "column": 7
}
}
},
@@ -4399,43 +6427,120 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 695,
- "end": 712,
+ "start": 928,
+ "end": 945,
"loc": {
"start": {
- "line": 28,
- "column": 4
+ "line": 39,
+ "column": 7
},
"end": {
- "line": 28,
- "column": 21
+ "line": 39,
+ "column": 24
}
}
},
{
"type": {
- "label": "=",
+ "label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
- "isAssign": true,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": 6,
+ "updateContext": null
+ },
+ "value": "===",
+ "start": 946,
+ "end": 949,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 25
+ },
+ "end": {
+ "line": 39,
+ "column": 28
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "string",
+ "beforeExpr": false,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
- "value": "=",
- "start": 713,
- "end": 714,
+ "value": "",
+ "start": 950,
+ "end": 952,
"loc": {
"start": {
- "line": 28,
- "column": 22
+ "line": 39,
+ "column": 29
},
"end": {
- "line": 28,
- "column": 23
+ "line": 39,
+ "column": 31
+ }
+ }
+ },
+ {
+ "type": {
+ "label": ")",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 952,
+ "end": 953,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 31
+ },
+ "end": {
+ "line": 39,
+ "column": 32
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "{",
+ "beforeExpr": true,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 953,
+ "end": 954,
+ "loc": {
+ "start": {
+ "line": 39,
+ "column": 32
+ },
+ "end": {
+ "line": 39,
+ "column": 33
}
}
},
@@ -4451,25 +6556,52 @@
"postfix": false,
"binop": null
},
- "value": "currentScriptPath",
- "start": 715,
- "end": 732,
+ "value": "rExtractUri",
+ "start": 961,
+ "end": 972,
"loc": {
"start": {
- "line": 28,
- "column": 24
+ "line": 40,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 41
+ "line": 40,
+ "column": 17
}
}
},
{
"type": {
- "label": ".",
+ "label": "=",
+ "beforeExpr": true,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": true,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "value": "=",
+ "start": 973,
+ "end": 974,
+ "loc": {
+ "start": {
+ "line": 40,
+ "column": 18
+ },
+ "end": {
+ "line": 40,
+ "column": 19
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "regexp",
"beforeExpr": false,
- "startsExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4478,49 +6610,53 @@
"binop": null,
"updateContext": null
},
- "start": 732,
- "end": 733,
+ "value": {
+ "pattern": "(?:http|https|file):\\/\\/.*?\\/.+?.js",
+ "flags": ""
+ },
+ "start": 975,
+ "end": 1012,
"loc": {
"start": {
- "line": 28,
- "column": 41
+ "line": 40,
+ "column": 20
},
"end": {
- "line": 28,
- "column": 42
+ "line": 40,
+ "column": 57
}
}
},
{
"type": {
- "label": "name",
- "beforeExpr": false,
- "startsExpr": true,
+ "label": ";",
+ "beforeExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null
+ "binop": null,
+ "updateContext": null
},
- "value": "replace",
- "start": 733,
- "end": 740,
+ "start": 1012,
+ "end": 1013,
"loc": {
"start": {
- "line": 28,
- "column": 42
+ "line": 40,
+ "column": 57
},
"end": {
- "line": 28,
- "column": 49
+ "line": 40,
+ "column": 58
}
}
},
{
"type": {
- "label": "(",
- "beforeExpr": true,
+ "label": "name",
+ "beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
@@ -4529,80 +6665,78 @@
"postfix": false,
"binop": null
},
- "start": 740,
- "end": 741,
+ "value": "absPath",
+ "start": 1020,
+ "end": 1027,
"loc": {
"start": {
- "line": 28,
- "column": 49
+ "line": 41,
+ "column": 6
},
"end": {
- "line": 28,
- "column": 50
+ "line": 41,
+ "column": 13
}
}
},
{
"type": {
- "label": "regexp",
- "beforeExpr": false,
- "startsExpr": true,
+ "label": "=",
+ "beforeExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
- "isAssign": false,
+ "isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
- "value": {
- "pattern": "[^/\\\\\\\\]+$",
- "flags": ""
- },
- "start": 741,
- "end": 753,
+ "value": "=",
+ "start": 1028,
+ "end": 1029,
"loc": {
"start": {
- "line": 28,
- "column": 50
+ "line": 41,
+ "column": 14
},
"end": {
- "line": 28,
- "column": 62
+ "line": 41,
+ "column": 15
}
}
},
{
"type": {
- "label": ",",
- "beforeExpr": true,
- "startsExpr": false,
+ "label": "name",
+ "beforeExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "start": 753,
- "end": 754,
+ "value": "rExtractUri",
+ "start": 1030,
+ "end": 1041,
"loc": {
"start": {
- "line": 28,
- "column": 62
+ "line": 41,
+ "column": 16
},
"end": {
- "line": 28,
- "column": 63
+ "line": 41,
+ "column": 27
}
}
},
{
"type": {
- "label": "string",
+ "label": ".",
"beforeExpr": false,
- "startsExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4611,25 +6745,24 @@
"binop": null,
"updateContext": null
},
- "value": "",
- "start": 755,
- "end": 757,
+ "start": 1041,
+ "end": 1042,
"loc": {
"start": {
- "line": 28,
- "column": 64
+ "line": 41,
+ "column": 27
},
"end": {
- "line": 28,
- "column": 66
+ "line": 41,
+ "column": 28
}
}
},
{
"type": {
- "label": ")",
+ "label": "name",
"beforeExpr": false,
- "startsExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4637,50 +6770,50 @@
"postfix": false,
"binop": null
},
- "start": 757,
- "end": 758,
+ "value": "exec",
+ "start": 1042,
+ "end": 1046,
"loc": {
"start": {
- "line": 28,
- "column": 66
+ "line": 41,
+ "column": 28
},
"end": {
- "line": 28,
- "column": 67
+ "line": 41,
+ "column": 32
}
}
},
{
"type": {
- "label": ";",
+ "label": "(",
"beforeExpr": true,
- "startsExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "start": 758,
- "end": 759,
+ "start": 1046,
+ "end": 1047,
"loc": {
"start": {
- "line": 28,
- "column": 67
+ "line": 41,
+ "column": 32
},
"end": {
- "line": 28,
- "column": 68
+ "line": 41,
+ "column": 33
}
}
},
{
"type": {
- "label": "}",
+ "label": "name",
"beforeExpr": false,
- "startsExpr": false,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4688,23 +6821,23 @@
"postfix": false,
"binop": null
},
- "start": 762,
- "end": 763,
+ "value": "stack",
+ "start": 1047,
+ "end": 1052,
"loc": {
"start": {
- "line": 29,
- "column": 2
+ "line": 41,
+ "column": 33
},
"end": {
- "line": 29,
- "column": 3
+ "line": 41,
+ "column": 38
}
}
},
{
"type": {
- "label": "if",
- "keyword": "if",
+ "label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
@@ -4712,45 +6845,44 @@
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "value": "if",
- "start": 767,
- "end": 769,
+ "start": 1052,
+ "end": 1053,
"loc": {
"start": {
- "line": 31,
- "column": 2
+ "line": 41,
+ "column": 38
},
"end": {
- "line": 31,
- "column": 4
+ "line": 41,
+ "column": 39
}
}
},
{
"type": {
- "label": "(",
+ "label": ";",
"beforeExpr": true,
- "startsExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null
+ "binop": null,
+ "updateContext": null
},
- "start": 770,
- "end": 771,
+ "start": 1053,
+ "end": 1054,
"loc": {
"start": {
- "line": 31,
- "column": 5
+ "line": 41,
+ "column": 39
},
"end": {
- "line": 31,
- "column": 6
+ "line": 41,
+ "column": 40
}
}
},
@@ -4767,50 +6899,49 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 771,
- "end": 788,
+ "start": 1061,
+ "end": 1078,
"loc": {
"start": {
- "line": 31,
+ "line": 42,
"column": 6
},
"end": {
- "line": 31,
+ "line": 42,
"column": 23
}
}
},
{
"type": {
- "label": "==/!=",
+ "label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
- "isAssign": false,
+ "isAssign": true,
"prefix": false,
"postfix": false,
- "binop": 6,
+ "binop": null,
"updateContext": null
},
- "value": "===",
- "start": 789,
- "end": 792,
+ "value": "=",
+ "start": 1079,
+ "end": 1080,
"loc": {
"start": {
- "line": 31,
+ "line": 42,
"column": 24
},
"end": {
- "line": 31,
- "column": 27
+ "line": 42,
+ "column": 25
}
}
},
{
"type": {
- "label": "null",
- "keyword": "null",
+ "label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
@@ -4818,78 +6949,79 @@
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "value": "null",
- "start": 793,
- "end": 797,
+ "value": "absPath",
+ "start": 1081,
+ "end": 1088,
"loc": {
"start": {
- "line": 31,
- "column": 28
+ "line": 42,
+ "column": 26
},
"end": {
- "line": 31,
- "column": 32
+ "line": 42,
+ "column": 33
}
}
},
{
"type": {
- "label": ")",
- "beforeExpr": false,
- "startsExpr": false,
+ "label": "[",
+ "beforeExpr": true,
+ "startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null
+ "binop": null,
+ "updateContext": null
},
- "start": 797,
- "end": 798,
+ "start": 1088,
+ "end": 1089,
"loc": {
"start": {
- "line": 31,
- "column": 32
+ "line": 42,
+ "column": 33
},
"end": {
- "line": 31,
- "column": 33
+ "line": 42,
+ "column": 34
}
}
},
{
"type": {
- "label": "{",
- "beforeExpr": true,
+ "label": "num",
+ "beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null
+ "binop": null,
+ "updateContext": null
},
- "start": 798,
- "end": 799,
+ "value": 0,
+ "start": 1089,
+ "end": 1090,
"loc": {
"start": {
- "line": 31,
- "column": 33
+ "line": 42,
+ "column": 34
},
"end": {
- "line": 31,
- "column": 34
+ "line": 42,
+ "column": 35
}
}
},
{
"type": {
- "label": "throw",
- "keyword": "throw",
- "beforeExpr": true,
+ "label": "]",
+ "beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
@@ -4899,25 +7031,24 @@
"binop": null,
"updateContext": null
},
- "value": "throw",
- "start": 804,
- "end": 809,
+ "start": 1090,
+ "end": 1091,
"loc": {
"start": {
- "line": 32,
- "column": 4
+ "line": 42,
+ "column": 35
},
"end": {
- "line": 32,
- "column": 9
+ "line": 42,
+ "column": 36
}
}
},
{
"type": {
- "label": "string",
- "beforeExpr": false,
- "startsExpr": true,
+ "label": ";",
+ "beforeExpr": true,
+ "startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
@@ -4926,43 +7057,41 @@
"binop": null,
"updateContext": null
},
- "value": "Cannot get currentScriptPath for wpPublicPath",
- "start": 810,
- "end": 857,
+ "start": 1091,
+ "end": 1092,
"loc": {
"start": {
- "line": 32,
- "column": 10
+ "line": 42,
+ "column": 36
},
"end": {
- "line": 32,
- "column": 57
+ "line": 42,
+ "column": 37
}
}
},
{
"type": {
- "label": ";",
- "beforeExpr": true,
+ "label": "}",
+ "beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
- "binop": null,
- "updateContext": null
+ "binop": null
},
- "start": 857,
- "end": 858,
+ "start": 1097,
+ "end": 1098,
"loc": {
"start": {
- "line": 32,
- "column": 57
+ "line": 43,
+ "column": 4
},
"end": {
- "line": 32,
- "column": 58
+ "line": 43,
+ "column": 5
}
}
},
@@ -4978,15 +7107,15 @@
"postfix": false,
"binop": null
},
- "start": 861,
- "end": 862,
+ "start": 1102,
+ "end": 1103,
"loc": {
"start": {
- "line": 33,
+ "line": 45,
"column": 2
},
"end": {
- "line": 33,
+ "line": 45,
"column": 3
}
}
@@ -5006,15 +7135,15 @@
"updateContext": null
},
"value": "return",
- "start": 866,
- "end": 872,
+ "start": 1107,
+ "end": 1113,
"loc": {
"start": {
- "line": 35,
+ "line": 47,
"column": 2
},
"end": {
- "line": 35,
+ "line": 47,
"column": 8
}
}
@@ -5032,15 +7161,15 @@
"binop": null
},
"value": "currentScriptPath",
- "start": 873,
- "end": 890,
+ "start": 1114,
+ "end": 1131,
"loc": {
"start": {
- "line": 35,
+ "line": 47,
"column": 9
},
"end": {
- "line": 35,
+ "line": 47,
"column": 26
}
}
@@ -5058,15 +7187,15 @@
"binop": null,
"updateContext": null
},
- "start": 890,
- "end": 891,
+ "start": 1131,
+ "end": 1132,
"loc": {
"start": {
- "line": 35,
+ "line": 47,
"column": 26
},
"end": {
- "line": 35,
+ "line": 47,
"column": 27
}
}
@@ -5083,15 +7212,15 @@
"postfix": false,
"binop": null
},
- "start": 893,
- "end": 894,
+ "start": 1134,
+ "end": 1135,
"loc": {
"start": {
- "line": 37,
+ "line": 49,
"column": 0
},
"end": {
- "line": 37,
+ "line": 49,
"column": 1
}
}
@@ -5099,15 +7228,15 @@
{
"type": "CommentLine",
"value": " expose the path to the global,",
- "start": 896,
- "end": 929,
+ "start": 1137,
+ "end": 1170,
"loc": {
"start": {
- "line": 39,
+ "line": 51,
"column": 0
},
"end": {
- "line": 39,
+ "line": 51,
"column": 33
}
}
@@ -5115,47 +7244,19 @@
{
"type": "CommentLine",
"value": " and wp will finish the following work",
- "start": 930,
- "end": 970,
+ "start": 1171,
+ "end": 1211,
"loc": {
"start": {
- "line": 40,
+ "line": 52,
"column": 0
},
"end": {
- "line": 40,
+ "line": 52,
"column": 40
}
}
},
- {
- "type": {
- "label": "var",
- "keyword": "var",
- "beforeExpr": false,
- "startsExpr": false,
- "rightAssociative": false,
- "isLoop": false,
- "isAssign": false,
- "prefix": false,
- "postfix": false,
- "binop": null,
- "updateContext": null
- },
- "value": "var",
- "start": 971,
- "end": 974,
- "loc": {
- "start": {
- "line": 41,
- "column": 0
- },
- "end": {
- "line": 41,
- "column": 3
- }
- }
- },
{
"type": {
"label": "name",
@@ -5169,16 +7270,16 @@
"binop": null
},
"value": "__webpack_public_path__",
- "start": 975,
- "end": 998,
+ "start": 1212,
+ "end": 1235,
"loc": {
"start": {
- "line": 41,
- "column": 4
+ "line": 53,
+ "column": 0
},
"end": {
- "line": 41,
- "column": 27
+ "line": 53,
+ "column": 23
}
}
},
@@ -5196,16 +7297,16 @@
"updateContext": null
},
"value": "=",
- "start": 999,
- "end": 1000,
+ "start": 1236,
+ "end": 1237,
"loc": {
"start": {
- "line": 41,
- "column": 28
+ "line": 53,
+ "column": 24
},
"end": {
- "line": 41,
- "column": 29
+ "line": 53,
+ "column": 25
}
}
},
@@ -5222,16 +7323,16 @@
"binop": null
},
"value": "getCurrentPath",
- "start": 1001,
- "end": 1015,
+ "start": 1238,
+ "end": 1252,
"loc": {
"start": {
- "line": 41,
- "column": 30
+ "line": 53,
+ "column": 26
},
"end": {
- "line": 41,
- "column": 44
+ "line": 53,
+ "column": 40
}
}
},
@@ -5247,16 +7348,16 @@
"postfix": false,
"binop": null
},
- "start": 1015,
- "end": 1016,
+ "start": 1252,
+ "end": 1253,
"loc": {
"start": {
- "line": 41,
- "column": 44
+ "line": 53,
+ "column": 40
},
"end": {
- "line": 41,
- "column": 45
+ "line": 53,
+ "column": 41
}
}
},
@@ -5272,16 +7373,16 @@
"postfix": false,
"binop": null
},
- "start": 1016,
- "end": 1017,
+ "start": 1253,
+ "end": 1254,
"loc": {
"start": {
- "line": 41,
- "column": 45
+ "line": 53,
+ "column": 41
},
"end": {
- "line": 41,
- "column": 46
+ "line": 53,
+ "column": 42
}
}
},
@@ -5298,16 +7399,16 @@
"binop": null,
"updateContext": null
},
- "start": 1017,
- "end": 1018,
+ "start": 1254,
+ "end": 1255,
"loc": {
"start": {
- "line": 41,
- "column": 46
+ "line": 53,
+ "column": 42
},
"end": {
- "line": 41,
- "column": 47
+ "line": 53,
+ "column": 43
}
}
},
@@ -5326,15 +7427,15 @@
"updateContext": null
},
"value": "if",
- "start": 1019,
- "end": 1021,
+ "start": 1256,
+ "end": 1258,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 0
},
"end": {
- "line": 42,
+ "line": 54,
"column": 2
}
}
@@ -5351,15 +7452,15 @@
"postfix": false,
"binop": null
},
- "start": 1022,
- "end": 1023,
+ "start": 1259,
+ "end": 1260,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 3
},
"end": {
- "line": 42,
+ "line": 54,
"column": 4
}
}
@@ -5377,15 +7478,15 @@
"binop": null
},
"value": "process",
- "start": 1023,
- "end": 1030,
+ "start": 1260,
+ "end": 1267,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 4
},
"end": {
- "line": 42,
+ "line": 54,
"column": 11
}
}
@@ -5403,15 +7504,15 @@
"binop": null,
"updateContext": null
},
- "start": 1030,
- "end": 1031,
+ "start": 1267,
+ "end": 1268,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 11
},
"end": {
- "line": 42,
+ "line": 54,
"column": 12
}
}
@@ -5429,15 +7530,15 @@
"binop": null
},
"value": "env",
- "start": 1031,
- "end": 1034,
+ "start": 1268,
+ "end": 1271,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 12
},
"end": {
- "line": 42,
+ "line": 54,
"column": 15
}
}
@@ -5455,15 +7556,15 @@
"binop": null,
"updateContext": null
},
- "start": 1034,
- "end": 1035,
+ "start": 1271,
+ "end": 1272,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 15
},
"end": {
- "line": 42,
+ "line": 54,
"column": 16
}
}
@@ -5481,15 +7582,15 @@
"binop": null
},
"value": "NODE_ENV",
- "start": 1035,
- "end": 1043,
+ "start": 1272,
+ "end": 1280,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 16
},
"end": {
- "line": 42,
+ "line": 54,
"column": 24
}
}
@@ -5508,15 +7609,15 @@
"updateContext": null
},
"value": "===",
- "start": 1044,
- "end": 1047,
+ "start": 1281,
+ "end": 1284,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 25
},
"end": {
- "line": 42,
+ "line": 54,
"column": 28
}
}
@@ -5535,15 +7636,15 @@
"updateContext": null
},
"value": "development",
- "start": 1048,
- "end": 1061,
+ "start": 1285,
+ "end": 1298,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 29
},
"end": {
- "line": 42,
+ "line": 54,
"column": 42
}
}
@@ -5560,15 +7661,15 @@
"postfix": false,
"binop": null
},
- "start": 1061,
- "end": 1062,
+ "start": 1298,
+ "end": 1299,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 42
},
"end": {
- "line": 42,
+ "line": 54,
"column": 43
}
}
@@ -5585,15 +7686,15 @@
"postfix": false,
"binop": null
},
- "start": 1062,
- "end": 1063,
+ "start": 1299,
+ "end": 1300,
"loc": {
"start": {
- "line": 42,
+ "line": 54,
"column": 43
},
"end": {
- "line": 42,
+ "line": 54,
"column": 44
}
}
@@ -5611,15 +7712,15 @@
"binop": null
},
"value": "console",
- "start": 1066,
- "end": 1073,
+ "start": 1303,
+ "end": 1310,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 2
},
"end": {
- "line": 43,
+ "line": 55,
"column": 9
}
}
@@ -5637,15 +7738,15 @@
"binop": null,
"updateContext": null
},
- "start": 1073,
- "end": 1074,
+ "start": 1310,
+ "end": 1311,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 9
},
"end": {
- "line": 43,
+ "line": 55,
"column": 10
}
}
@@ -5663,15 +7764,15 @@
"binop": null
},
"value": "log",
- "start": 1074,
- "end": 1077,
+ "start": 1311,
+ "end": 1314,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 10
},
"end": {
- "line": 43,
+ "line": 55,
"column": 13
}
}
@@ -5688,15 +7789,15 @@
"postfix": false,
"binop": null
},
- "start": 1077,
- "end": 1078,
+ "start": 1314,
+ "end": 1315,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 13
},
"end": {
- "line": 43,
+ "line": 55,
"column": 14
}
}
@@ -5713,15 +7814,15 @@
"postfix": false,
"binop": null
},
- "start": 1078,
- "end": 1079,
+ "start": 1315,
+ "end": 1316,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 14
},
"end": {
- "line": 43,
+ "line": 55,
"column": 15
}
}
@@ -5740,15 +7841,15 @@
"updateContext": null
},
"value": "wpPP: publicPath: ",
- "start": 1079,
- "end": 1097,
+ "start": 1316,
+ "end": 1334,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 15
},
"end": {
- "line": 43,
+ "line": 55,
"column": 33
}
}
@@ -5765,15 +7866,15 @@
"postfix": false,
"binop": null
},
- "start": 1097,
- "end": 1099,
+ "start": 1334,
+ "end": 1336,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 33
},
"end": {
- "line": 43,
+ "line": 55,
"column": 35
}
}
@@ -5791,15 +7892,15 @@
"binop": null
},
"value": "__webpack_public_path__",
- "start": 1099,
- "end": 1122,
+ "start": 1336,
+ "end": 1359,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 35
},
"end": {
- "line": 43,
+ "line": 55,
"column": 58
}
}
@@ -5816,15 +7917,15 @@
"postfix": false,
"binop": null
},
- "start": 1122,
- "end": 1123,
+ "start": 1359,
+ "end": 1360,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 58
},
"end": {
- "line": 43,
+ "line": 55,
"column": 59
}
}
@@ -5843,15 +7944,15 @@
"updateContext": null
},
"value": "",
- "start": 1123,
- "end": 1123,
+ "start": 1360,
+ "end": 1360,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 59
},
"end": {
- "line": 43,
+ "line": 55,
"column": 59
}
}
@@ -5868,15 +7969,15 @@
"postfix": false,
"binop": null
},
- "start": 1123,
- "end": 1124,
+ "start": 1360,
+ "end": 1361,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 59
},
"end": {
- "line": 43,
+ "line": 55,
"column": 60
}
}
@@ -5893,15 +7994,15 @@
"postfix": false,
"binop": null
},
- "start": 1124,
- "end": 1125,
+ "start": 1361,
+ "end": 1362,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 60
},
"end": {
- "line": 43,
+ "line": 55,
"column": 61
}
}
@@ -5919,15 +8020,15 @@
"binop": null,
"updateContext": null
},
- "start": 1125,
- "end": 1126,
+ "start": 1362,
+ "end": 1363,
"loc": {
"start": {
- "line": 43,
+ "line": 55,
"column": 61
},
"end": {
- "line": 43,
+ "line": 55,
"column": 62
}
}
@@ -5944,15 +8045,145 @@
"postfix": false,
"binop": null
},
- "start": 1127,
- "end": 1128,
+ "start": 1364,
+ "end": 1365,
+ "loc": {
+ "start": {
+ "line": 56,
+ "column": 0
+ },
+ "end": {
+ "line": 56,
+ "column": 1
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "export",
+ "keyword": "export",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "value": "export",
+ "start": 1367,
+ "end": 1373,
+ "loc": {
+ "start": {
+ "line": 58,
+ "column": 0
+ },
+ "end": {
+ "line": 58,
+ "column": 6
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "{",
+ "beforeExpr": true,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 1374,
+ "end": 1375,
+ "loc": {
+ "start": {
+ "line": 58,
+ "column": 7
+ },
+ "end": {
+ "line": 58,
+ "column": 8
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "name",
+ "beforeExpr": false,
+ "startsExpr": true,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "value": "getCurrentPath",
+ "start": 1378,
+ "end": 1392,
+ "loc": {
+ "start": {
+ "line": 59,
+ "column": 2
+ },
+ "end": {
+ "line": 59,
+ "column": 16
+ }
+ }
+ },
+ {
+ "type": {
+ "label": ",",
+ "beforeExpr": true,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null,
+ "updateContext": null
+ },
+ "start": 1392,
+ "end": 1393,
+ "loc": {
+ "start": {
+ "line": 59,
+ "column": 16
+ },
+ "end": {
+ "line": 59,
+ "column": 17
+ }
+ }
+ },
+ {
+ "type": {
+ "label": "}",
+ "beforeExpr": false,
+ "startsExpr": false,
+ "rightAssociative": false,
+ "isLoop": false,
+ "isAssign": false,
+ "prefix": false,
+ "postfix": false,
+ "binop": null
+ },
+ "start": 1394,
+ "end": 1395,
"loc": {
"start": {
- "line": 44,
+ "line": 60,
"column": 0
},
"end": {
- "line": 44,
+ "line": 60,
"column": 1
}
}
@@ -5970,15 +8201,15 @@
"binop": null,
"updateContext": null
},
- "start": 1129,
- "end": 1129,
+ "start": 1396,
+ "end": 1396,
"loc": {
"start": {
- "line": 45,
+ "line": 61,
"column": 0
},
"end": {
- "line": 45,
+ "line": 61,
"column": 0
}
}
diff --git a/ghpages/docs/badge.svg b/ghpages/docs/badge.svg
index a866938..b8e6201 100644
--- a/ghpages/docs/badge.svg
+++ b/ghpages/docs/badge.svg
@@ -11,7 +11,7 @@
document
document
- 18%
- 18%
+ 19%
+ 19%
diff --git a/ghpages/docs/coverage.json b/ghpages/docs/coverage.json
index 44994d5..f99a4b3 100644
--- a/ghpages/docs/coverage.json
+++ b/ghpages/docs/coverage.json
@@ -1,7 +1,7 @@
{
- "coverage": "18.68%",
- "expectCount": 305,
- "actualCount": 57,
+ "coverage": "19.07%",
+ "expectCount": 304,
+ "actualCount": 58,
"files": {
"src/config/configMgr.js": {
"expectCount": 3,
@@ -247,12 +247,9 @@
"undocumentLines": []
},
"src/wpPublicPath.js": {
- "expectCount": 2,
- "actualCount": 0,
- "undocumentLines": [
- 8,
- 41
- ]
+ "expectCount": 1,
+ "actualCount": 1,
+ "undocumentLines": []
},
"src/_canvasManager.js": {
"expectCount": 3,
diff --git a/ghpages/docs/file/src/_PlatformManager.js.html b/ghpages/docs/file/src/_PlatformManager.js.html
index c7323d6..5c0d50a 100644
--- a/ghpages/docs/file/src/_PlatformManager.js.html
+++ b/ghpages/docs/file/src/_PlatformManager.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_cDefine.js.html b/ghpages/docs/file/src/_cDefine.js.html
index 63be67f..494432a 100644
--- a/ghpages/docs/file/src/_cDefine.js.html
+++ b/ghpages/docs/file/src/_cDefine.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_cLive2DApp.js.html b/ghpages/docs/file/src/_cLive2DApp.js.html
index 48218f8..61391f2 100644
--- a/ghpages/docs/file/src/_cLive2DApp.js.html
+++ b/ghpages/docs/file/src/_cLive2DApp.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_cManager.js.html b/ghpages/docs/file/src/_cManager.js.html
index 43ef62e..d94378a 100644
--- a/ghpages/docs/file/src/_cManager.js.html
+++ b/ghpages/docs/file/src/_cManager.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_cModel.js.html b/ghpages/docs/file/src/_cModel.js.html
index 9b9c7b7..a00cd28 100644
--- a/ghpages/docs/file/src/_cModel.js.html
+++ b/ghpages/docs/file/src/_cModel.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_canvasManager.js.html b/ghpages/docs/file/src/_canvasManager.js.html
index 06e6d26..7651422 100644
--- a/ghpages/docs/file/src/_canvasManager.js.html
+++ b/ghpages/docs/file/src/_canvasManager.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/_webglcontext.js.html b/ghpages/docs/file/src/_webglcontext.js.html
index 59071d7..4a3c204 100644
--- a/ghpages/docs/file/src/_webglcontext.js.html
+++ b/ghpages/docs/file/src/_webglcontext.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/config/configMgr.js.html b/ghpages/docs/file/src/config/configMgr.js.html
index e006f16..f0c4e66 100644
--- a/ghpages/docs/file/src/config/configMgr.js.html
+++ b/ghpages/docs/file/src/config/configMgr.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
@@ -99,7 +100,7 @@
function configApplyer(userConfig){
- if (!(_.has(userConfig, '_'))){
+ if (_.has(userConfig, '_')){
import(/* webpackMode: "lazy" */ './configValidater').then(f => {
f.configValidater(userConfig);
}).catch(err => {
diff --git a/ghpages/docs/file/src/config/configValidater.js.html b/ghpages/docs/file/src/config/configValidater.js.html
index 1ebfbd8..8829411 100644
--- a/ghpages/docs/file/src/config/configValidater.js.html
+++ b/ghpages/docs/file/src/config/configValidater.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/index.js.html b/ghpages/docs/file/src/index.js.html
index 04eadab..6c7fbf6 100644
--- a/ghpages/docs/file/src/index.js.html
+++ b/ghpages/docs/file/src/index.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
@@ -67,7 +68,7 @@
* @param {Object} userConfig User's config
*/
-export function init(userConfig){
+function init(userConfig){
userConfig = typeof userConfig === 'undefined' ? {} : userConfig;
@@ -90,6 +91,10 @@
});
}
+
+export {
+ init,
+}
diff --git a/ghpages/docs/file/src/lib/_Live2DFramework.js.html b/ghpages/docs/file/src/lib/_Live2DFramework.js.html
index ab5eb04..0c01c3c 100644
--- a/ghpages/docs/file/src/lib/_Live2DFramework.js.html
+++ b/ghpages/docs/file/src/lib/_Live2DFramework.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/lib/_Live2DFramework.official.js.html b/ghpages/docs/file/src/lib/_Live2DFramework.official.js.html
index dde4b54..286b295 100644
--- a/ghpages/docs/file/src/lib/_Live2DFramework.official.js.html
+++ b/ghpages/docs/file/src/lib/_Live2DFramework.official.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/lib/_live2d.min.js.html b/ghpages/docs/file/src/lib/_live2d.min.js.html
index 830f204..501bd26 100644
--- a/ghpages/docs/file/src/lib/_live2d.min.js.html
+++ b/ghpages/docs/file/src/lib/_live2d.min.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/utils/_MatrixStack.js.html b/ghpages/docs/file/src/utils/_MatrixStack.js.html
index 6286eb2..651e683 100644
--- a/ghpages/docs/file/src/utils/_MatrixStack.js.html
+++ b/ghpages/docs/file/src/utils/_MatrixStack.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/utils/_ModelSettingJson.js.html b/ghpages/docs/file/src/utils/_ModelSettingJson.js.html
index 66ff7e1..3edcbf1 100644
--- a/ghpages/docs/file/src/utils/_ModelSettingJson.js.html
+++ b/ghpages/docs/file/src/utils/_ModelSettingJson.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/file/src/wpPublicPath.js.html b/ghpages/docs/file/src/wpPublicPath.js.html
index 03e660d..9599a4f 100644
--- a/ghpages/docs/file/src/wpPublicPath.js.html
+++ b/ghpages/docs/file/src/wpPublicPath.js.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
@@ -47,12 +48,19 @@
src/wpPublicPath.js
/**
- * @description Automatic locate the publicPath for webpack
+ * @description Automatic locate the publicPath and set it up for webpack
*/
'use strict';
+/**
+ * Get current script path
+ * @return {String} The accessable path of current script
+ * @example
+ * get 'dev/' or 'https://www.host.com/test/js/'
+ */
+
function getCurrentPath(){
let currentScriptPath = null;
@@ -69,15 +77,20 @@
// IE 10 +, Safari and Opera 9
// console.log('Stage2');
+ // console.log(e);
+
let stack = e.stack || e.sourceURL || e.stacktrace,
- rExtractUri = /(?:http|https|file):\/\/.*?\/.+?.js/,
- absPath = rExtractUri.exec(stack);
- currentScriptPath = absPath[0] || '';
- currentScriptPath = currentScriptPath.replace(/[^/\\\\]+$/, '');
- }
+ rExtractUri = /(file:\/{3}\w:)(\/[^\/]*){3}\//;
+ // TODO: Fix wrong RegExp: rExtractUri
+ let absPath = rExtractUri.exec(stack);
+ currentScriptPath = absPath[0];
+
+ if(currentScriptPath === ''){
+ rExtractUri = /(?:http|https|file):\/\/.*?\/.+?.js/;
+ absPath = rExtractUri.exec(stack);
+ currentScriptPath = absPath[0];
+ }
- if (currentScriptPath === null){
- throw 'Cannot get currentScriptPath for wpPublicPath';
}
return currentScriptPath;
@@ -86,10 +99,14 @@
// expose the path to the global,
// and wp will finish the following work
-var __webpack_public_path__ = getCurrentPath();
+__webpack_public_path__ = getCurrentPath();
if (process.env.NODE_ENV === 'development'){
console.log(`wpPP: publicPath: ${__webpack_public_path__}`);
}
+
+export {
+ getCurrentPath,
+}
diff --git a/ghpages/docs/function/index.html b/ghpages/docs/function/index.html
index 6e2bafb..d9678ad 100644
--- a/ghpages/docs/function/index.html
+++ b/ghpages/docs/function/index.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
@@ -283,6 +284,35 @@
+
+
+
+
+
+
+
+ Get current script path
+
+
+ |
+
+
+
+ |
+
+
+
+ public
+
+
+
|
@@ -883,6 +913,70 @@ Return:
+
+
+
+ public
+
+
+
+
+
+ getCurrentPath(): String
+
+
+
+ source
+
+
+
+
+
+
+ Get current script path
+
+
+
+
+
+
+
+
+ Return:
+
+
+
+ String |
+ The accessable path of current script
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Example:
+
+
+
+ get 'dev/' or 'https://www.host.com/test/js/'
+
+
+
+
+
+
+
|
+
+
+ public
+
+
+
+
+ |
+
+
+
+
+
+ Get current script path
+
+
+ |
+
+
+
|
diff --git a/ghpages/docs/index.html b/ghpages/docs/index.html
index cc78f35..6d54934 100644
--- a/ghpages/docs/index.html
+++ b/ghpages/docs/index.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
diff --git a/ghpages/docs/index.json b/ghpages/docs/index.json
index fb72c12..dbd8cb8 100644
--- a/ghpages/docs/index.json
+++ b/ghpages/docs/index.json
@@ -567,7 +567,7 @@
"__docId__": 48,
"kind": "file",
"name": "src/config/configMgr.js",
- "content": "// Created by xiazeyu.\n\n/**\n * @description The container of configeration.\n */\n\n\n'use strict';\n\nimport _ from 'lodash';\n\nlet currConfig = {};\n\nconst defaultOptions = {\n model: {\n jsonPath: '', // string\n hHeadPos: 0.5, // horizontalHeadPos\n vHeadPos: 0.618, // verticalHeadPos\n myDefine: {},\n },\n display: {\n AA: 2, // antialiasing Grade 抗锯齿等级\n widght: 150,\n height: 300,\n scale: 1,\n position: 'right',\n hOffset: 0, // horizontalOffset\n vOffset: -20, // verticalOffset\n },\n mobile: {\n show: true,\n scale: 0.5,\n motion: false,\n },\n name: {\n canvas: 'live2dcanvas',\n div: 'live2d-widget',\n },\n react: {\n opacityDefault: 0.7,\n opacityOnHover: 0.2,\n myFunc: (e) => {console.log('(undefined) ┑( ̄Д  ̄)┍');}, // e means the event\n },\n debug: {\n log: false,\n mouseLog: false,\n mouseFunc: (x, y) => {console.log(`MouseFunc: ${x},${x}`);}, // only works when debug.mouseLog is on\n },\n _: true,\n}\n\nfunction configApplyer(userConfig){\n\n if (!(_.has(userConfig, '_'))){\n import(/* webpackMode: \"lazy\" */ './configValidater').then(f => {\n f.configValidater(userConfig);\n }).catch(err => {\n console.error(err);\n });\n }\n\n currConfig = _.defaultsDeep(userConfig, defaultOptions);\n\n}\n\nexport {\n configApplyer,\n currConfig as config,\n}\n",
+ "content": "// Created by xiazeyu.\n\n/**\n * @description The container of configeration.\n */\n\n\n'use strict';\n\nimport _ from 'lodash';\n\nlet currConfig = {};\n\nconst defaultOptions = {\n model: {\n jsonPath: '', // string\n hHeadPos: 0.5, // horizontalHeadPos\n vHeadPos: 0.618, // verticalHeadPos\n myDefine: {},\n },\n display: {\n AA: 2, // antialiasing Grade 抗锯齿等级\n widght: 150,\n height: 300,\n scale: 1,\n position: 'right',\n hOffset: 0, // horizontalOffset\n vOffset: -20, // verticalOffset\n },\n mobile: {\n show: true,\n scale: 0.5,\n motion: false,\n },\n name: {\n canvas: 'live2dcanvas',\n div: 'live2d-widget',\n },\n react: {\n opacityDefault: 0.7,\n opacityOnHover: 0.2,\n myFunc: (e) => {console.log('(undefined) ┑( ̄Д  ̄)┍');}, // e means the event\n },\n debug: {\n log: false,\n mouseLog: false,\n mouseFunc: (x, y) => {console.log(`MouseFunc: ${x},${x}`);}, // only works when debug.mouseLog is on\n },\n _: true,\n}\n\nfunction configApplyer(userConfig){\n\n if (_.has(userConfig, '_')){\n import(/* webpackMode: \"lazy\" */ './configValidater').then(f => {\n f.configValidater(userConfig);\n }).catch(err => {\n console.error(err);\n });\n }\n\n currConfig = _.defaultsDeep(userConfig, defaultOptions);\n\n}\n\nexport {\n configApplyer,\n currConfig as config,\n}\n",
"static": true,
"longname": "D:/git/live2d-widget.js/src/config/configMgr.js",
"access": "public",
@@ -683,7 +683,7 @@
"__docId__": 54,
"kind": "file",
"name": "src/index.js",
- "content": "// Created by xiazeyu.\n\n////////////////////////////////////\n// Celebrate for the 3.0 version! //\n////////////////////////////////////\n\n/**\n * @description The entry point of live2d-widget\n */\n\n\n'use strict';\n\nimport device from 'current-device';\nimport { config, configApplyer }from './config/configMgr';\n\n/**\n * The public entry point\n * @param {Object} userConfig User's config\n */\n\nexport function init(userConfig){\n\n userConfig = typeof userConfig === 'undefined' ? {} : userConfig;\n\n if (process.env.NODE_ENV === 'development'){\n console.log('--- --- --- --- ---');\n console.log('Hey that, notice that you are now in DEV MODE.');\n console.log('--- --- --- --- ---');\n }\n\n configApplyer(userConfig);\n\n if((!config.mobile.show)&&(device.mobile())){\n return;\n }\n\n import(/* webpackMode: \"lazy\" */ './_cLive2DApp').then(f => {\n f.default();\n }).catch(err => {\n console.error(err);\n });\n\n}\n",
+ "content": "// Created by xiazeyu.\n\n////////////////////////////////////\n// Celebrate for the 3.0 version! //\n////////////////////////////////////\n\n/**\n * @description The entry point of live2d-widget\n */\n\n\n'use strict';\n\nimport device from 'current-device';\nimport { config, configApplyer }from './config/configMgr';\n\n/**\n * The public entry point\n * @param {Object} userConfig User's config\n */\n\nfunction init(userConfig){\n\n userConfig = typeof userConfig === 'undefined' ? {} : userConfig;\n\n if (process.env.NODE_ENV === 'development'){\n console.log('--- --- --- --- ---');\n console.log('Hey that, notice that you are now in DEV MODE.');\n console.log('--- --- --- --- ---');\n }\n\n configApplyer(userConfig);\n\n if((!config.mobile.show)&&(device.mobile())){\n return;\n }\n\n import(/* webpackMode: \"lazy\" */ './_cLive2DApp').then(f => {\n f.default();\n }).catch(err => {\n console.error(err);\n });\n\n}\n\nexport {\n init,\n}\n",
"static": true,
"longname": "D:/git/live2d-widget.js/src/index.js",
"access": "public",
@@ -8171,7 +8171,7 @@
"__docId__": 305,
"kind": "file",
"name": "src/wpPublicPath.js",
- "content": "/**\n * @description Automatic locate the publicPath for webpack\n */\n\n\n'use strict';\n\nfunction getCurrentPath(){\n\n let currentScriptPath = null;\n\n try{\n // FF, Chrome\n // use their API to get the path of current script\n\n // a.b();\n // console.log('Stage1');\n let currentScriptElement = document.currentScript;\n currentScriptPath = currentScriptElement.getAttribute('src').replace(/[^/\\\\\\\\]+$/, '');\n }catch(e){\n // IE 10 +, Safari and Opera 9\n\n // console.log('Stage2');\n let stack = e.stack || e.sourceURL || e.stacktrace,\n rExtractUri = /(?:http|https|file):\\/\\/.*?\\/.+?.js/,\n absPath = rExtractUri.exec(stack);\n currentScriptPath = absPath[0] || '';\n currentScriptPath = currentScriptPath.replace(/[^/\\\\\\\\]+$/, '');\n }\n\n if (currentScriptPath === null){\n throw 'Cannot get currentScriptPath for wpPublicPath';\n }\n\n return currentScriptPath;\n\n}\n\n// expose the path to the global,\n// and wp will finish the following work\nvar __webpack_public_path__ = getCurrentPath();\nif (process.env.NODE_ENV === 'development'){\n console.log(`wpPP: publicPath: ${__webpack_public_path__}`);\n}\n",
+ "content": "/**\n * @description Automatic locate the publicPath and set it up for webpack\n */\n\n\n'use strict';\n\n/**\n * Get current script path\n * @return {String} The accessable path of current script\n * @example\n * get 'dev/' or 'https://www.host.com/test/js/'\n */\n\nfunction getCurrentPath(){\n\n let currentScriptPath = null;\n\n try{\n // FF, Chrome\n // use their API to get the path of current script\n\n // a.b();\n // console.log('Stage1');\n let currentScriptElement = document.currentScript;\n currentScriptPath = currentScriptElement.getAttribute('src').replace(/[^/\\\\\\\\]+$/, '');\n }catch(e){\n // IE 10 +, Safari and Opera 9\n\n // console.log('Stage2');\n // console.log(e);\n\n let stack = e.stack || e.sourceURL || e.stacktrace,\n rExtractUri = /(file:\\/{3}\\w:)(\\/[^\\/]*){3}\\//;\n // TODO: Fix wrong RegExp: rExtractUri\n let absPath = rExtractUri.exec(stack);\n currentScriptPath = absPath[0];\n\n if(currentScriptPath === ''){\n rExtractUri = /(?:http|https|file):\\/\\/.*?\\/.+?.js/;\n absPath = rExtractUri.exec(stack);\n currentScriptPath = absPath[0];\n }\n\n }\n\n return currentScriptPath;\n\n}\n\n// expose the path to the global,\n// and wp will finish the following work\n__webpack_public_path__ = getCurrentPath();\nif (process.env.NODE_ENV === 'development'){\n console.log(`wpPP: publicPath: ${__webpack_public_path__}`);\n}\n\nexport {\n getCurrentPath,\n}\n",
"static": true,
"longname": "D:/git/live2d-widget.js/src/wpPublicPath.js",
"access": "public",
@@ -8188,43 +8188,26 @@
"static": true,
"longname": "src/wpPublicPath.js~getCurrentPath",
"access": "public",
- "export": false,
+ "export": true,
"importPath": "live2d-widget/src/wpPublicPath.js",
- "importStyle": null,
- "description": null,
- "lineNumber": 8,
- "undocument": true,
- "params": [],
+ "importStyle": "{getCurrentPath}",
+ "description": "Get current script path",
+ "examples": [
+ "get 'dev/' or 'https://www.host.com/test/js/'"
+ ],
+ "lineNumber": 15,
"return": {
+ "nullable": null,
"types": [
- "*"
- ]
+ "String"
+ ],
+ "spread": false,
+ "description": "The accessable path of current script"
},
- "ignore": true
+ "params": []
},
{
"__docId__": 307,
- "kind": "variable",
- "name": "__webpack_public_path__",
- "memberof": "src/wpPublicPath.js",
- "static": true,
- "longname": "src/wpPublicPath.js~__webpack_public_path__",
- "access": "private",
- "export": false,
- "importPath": "live2d-widget/src/wpPublicPath.js",
- "importStyle": null,
- "description": null,
- "lineNumber": 41,
- "undocument": true,
- "type": {
- "types": [
- "*"
- ]
- },
- "ignore": true
- },
- {
- "__docId__": 308,
"kind": "file",
"name": "src/_canvasManager.js",
"content": "// Modified by xiazeyu.\n\n/**\n* @desc A library to create and init canvas.\n*/\n\nconst htmlTemplate = require('../tmplate/innerHTML.html')\n\nexport function createCanvas(canvasID) {\n\n}\n\n\nexport function initCanvas(canvasId) {\n canvas = document.getElementById(canvasId);\n if (canvas.addEventListener) {\n window.addEventListener(\"click\", mouseEvent);\n window.addEventListener(\"mousedown\", mouseEvent);\n window.addEventListener(\"mousemove\", mouseEvent);\n window.addEventListener(\"mouseup\", mouseEvent);\n document.addEventListener(\"mouseleave\", mouseEvent);\n window.addEventListener(\"touchstart\", touchEvent);\n window.addEventListener(\"touchend\", touchEvent);\n window.addEventListener(\"touchmove\", touchEvent);\n }\n}\n",
@@ -8235,7 +8218,7 @@
"lineNumber": 1
},
{
- "__docId__": 309,
+ "__docId__": 308,
"kind": "variable",
"name": "htmlTemplate",
"memberof": "src/_canvasManager.js",
@@ -8255,7 +8238,7 @@
"ignore": true
},
{
- "__docId__": 310,
+ "__docId__": 309,
"kind": "function",
"name": "createCanvas",
"memberof": "src/_canvasManager.js",
@@ -8281,7 +8264,7 @@
"return": null
},
{
- "__docId__": 311,
+ "__docId__": 310,
"kind": "function",
"name": "initCanvas",
"memberof": "src/_canvasManager.js",
@@ -8307,7 +8290,7 @@
"return": null
},
{
- "__docId__": 312,
+ "__docId__": 311,
"kind": "file",
"name": "src/_cDefine.js",
"content": "// Modified by xiazeyu.\n\n/**\n* @desc The definitions of values releated to model react\n*/\n\nvar cDefine = {\n // above are viewMatrix value settings\n VIEW_LOGICAL_LEFT : -1, // -1, the left abscissa of viewMatrix\n VIEW_LOGICAL_RIGHT : 1, // 1, the right abscissa of viewMatrix\n VIEW_LOGICAL_MAX_LEFT : -2, // -2, the max left abscissa of viewMatrix\n VIEW_LOGICAL_MAX_RIGHT : 2, // 2, the max right abscissa of viewMatrix\n VIEW_LOGICAL_MAX_BOTTOM : -2, // -2, the max bottom abscissa of viewMatrix\n VIEW_LOGICAL_MAX_TOP : 2, // 2, the max top abscissa of viewMatrix\n\n // above are the motions priority settings.\n PRIORITY_NONE : 0, // 0,do nothing\n PRIORITY_IDLE : 1, // 1, idle motions\n PRIORITY_NORMAL : 2, // 2, normal motions\n PRIORITY_FORCE : 3, // 3, force to show motion\n\n // above are the index to the motions in model.json\n // #43\n MOTION_GROUP_IDLE : \"idle\",\n MOTION_GROUP_TAP_BODY : \"tap_body\",\n MOTION_GROUP_FLICK_HEAD : \"flick_head\", // unused\n MOTION_GROUP_PINCH_IN : \"pinch_in\", // unused\n MOTION_GROUP_PINCH_OUT : \"pinch_out\", // unused\n MOTION_GROUP_SHAKE : \"shake\", // unused\n\n // above are the index to the hit areas in model.json\n // #43\n HIT_AREA_HEAD : \"head\",\n HIT_AREA_BODY : \"body\"\n};\n\nmodule.exports = cDefine;\n",
@@ -8318,7 +8301,7 @@
"lineNumber": 1
},
{
- "__docId__": 313,
+ "__docId__": 312,
"kind": "variable",
"name": "cDefine",
"memberof": "src/_cDefine.js",
@@ -8338,7 +8321,7 @@
"ignore": true
},
{
- "__docId__": 314,
+ "__docId__": 313,
"kind": "file",
"name": "src/_cLive2DApp.js",
"content": "/*import {\n UtSystem,\n UtDebug,\n LDTransform,\n LDGL,\n Live2D,\n Live2DModelWebGL,\n Live2DModelJS,\n Live2DMotion,\n MotionQueueManager,\n PhysicsHair,\n AMotion,\n PartsDataID,\n DrawDataID,\n BaseDataID,\n ParamID\n} from './lib/live2d.min';*//*\nimport './lib/live2d.min.js';\nimport { createCanvas, initCanvas } from \"./lib/canvasManager\";\nimport { device } from 'current-device';\nimport { L2DTargetPoint, L2DViewMatrix, L2DMatrix44 } from \"./lib/Live2DFramework\";\nimport cManager from \"./cManager\";\nimport { MatrixStack } from \"./utils/MatrixStack\";\nimport { setContext } from \"./lib/webGLContext\";\nimport { cDefine } from \"./cDefine\";\n\nconst live2DMgr = new cManager();\nlet isDrawStart = false;\nlet gl = null;\nlet canvas = null;\nlet dragMgr = null;\nlet viewMatrix = null;\nlet projMatrix = null;\nlet deviceToScreen = null;\nlet drag = false;\nlet lastMouseX = 0;\nlet lastMouseY = 0;\nlet headPos = 0.5;\nlet opacityDefault = 0.7;\nlet opacityHover = 1;\n*/\n\nimport { config }from './config/configMgr.js';\n\nexport default () => {\n console.log('config:');\n console.log(config);\n/*\n headPos = typeof iHeadPos === 'undefined' ? 0.5 : iHeadPos;\n opacityDefault = typeof iOpacityDefault === 'undefined' ? 0.7 : iOpacityDefault;\n opacityHover = typeof iOpacityHover === 'undefined' ? 1 : iOpacityHover;\n initSettings();\n createCanvas(iID);\n initCanvas(iID);\n init(iModelUrl);*/\n}\n\n\nfunction init(modelUrl) {\n // 此处获取的是canvas的大小 即绘制大小,与实际显示大小无关\n let width = canvas.width;\n let height = canvas.height;\n // 以下为实际显示大小\n // #32\n let sWidth = parseInt(canvas.style.width);\n let sHeight = parseInt(canvas.style.height);\n\n dragMgr = new L2DTargetPoint();\n let ratio = height / width;\n let left = cDefine.VIEW_LOGICAL_LEFT;\n let right = cDefine.VIEW_LOGICAL_RIGHT;\n let bottom = -ratio;\n let top = ratio;\n\n viewMatrix = new L2DViewMatrix();\n\n viewMatrix.setScreenRect(left, right, bottom, top);\n\n viewMatrix.setMaxScreenRect(cDefine.VIEW_LOGICAL_MAX_LEFT,\n cDefine.VIEW_LOGICAL_MAX_RIGHT,\n cDefine.VIEW_LOGICAL_MAX_BOTTOM,\n cDefine.VIEW_LOGICAL_MAX_TOP);\n\n projMatrix = new L2DMatrix44();\n projMatrix.multScale(1, (width / height));\n\n deviceToScreen = new L2DMatrix44();\n // deviceToScreen.multTranslate(-width / 2.0, -height / 2.0); // old codes\n // deviceToScreen.multScale(2 / width, -2 / width); // old codes\n deviceToScreen.multTranslate(-sWidth / 2.0, -sHeight / 2.0); // #32\n deviceToScreen.multScale(2 / sWidth, -2 / sHeight); // #32\n\n gl = getWebGLContext();\n setContext(gl);\n if (!gl) { // Check if WebGL element is created successfully.\n console.error(\"Failed to create WebGL context.\");\n if(!window.WebGLRenderingContext){\n console.error(\"Your browser don't support WebGL, check https://get.webgl.org/ for futher information.\");\n }\n return;\n }\n window.Live2D.setGL(gl);\n gl.clearColor(0.0, 0.0, 0.0, 0.0);\n changeModel(modelUrl);\n startDraw();\n}\n\nfunction startDraw() {\n if (!isDrawStart) {\n isDrawStart = true;\n (function tick() {\n draw();\n let requestAnimationFrame =\n window.requestAnimationFrame ||\n window.mozRequestAnimationFrame ||\n window.webkitRequestAnimationFrame ||\n window.msRequestAnimationFrame;\n\n requestAnimationFrame(tick, canvas);\n })();\n }\n}\n\nfunction draw()\n{\n MatrixStack.reset();\n MatrixStack.loadIdentity();\n dragMgr.update();\n live2DMgr.setDrag(dragMgr.getX(), dragMgr.getY());\n\n gl.clear(gl.COLOR_BUFFER_BIT);\n\n MatrixStack.multMatrix(projMatrix.getArray());\n MatrixStack.multMatrix(viewMatrix.getArray());\n MatrixStack.push();\n\n for (let i = 0; i < live2DMgr.numModels(); i++)\n {\n let model = live2DMgr.getModel(i);\n\n if(model == null) return;\n\n if (model.initialized && !model.updating)\n {\n model.update();\n model.draw(gl);\n }\n }\n MatrixStack.pop();\n}\n\nfunction changeModel(modelurl) // 更换模型\n{\n live2DMgr.reloadFlg = true;\n live2DMgr.count++; // 现在仍有多模型支持,稍后可以精简\n live2DMgr.changeModel(gl, modelurl);\n}\n\nfunction modelScaling(scale) {\n viewMatrix.adjustScale(0, 0, scale);\n}\n/*\nfunction transformRange(center, transform, range)\n{\n let a = {\n x: transform.x - center.x,\n y: transform.y - center.y\n }\n let r = Math.sqrt(Math.pow(a.x,2) + Math.pow(a.y,2));\n if (r > range) {\n a = {\n x: a.x / r * range + center.x,\n y: a.y / r * range + center.y\n };\n return a;\n } else {\n return transform;\n }\n}\n*/\nfunction dot(A,B)\n{\n return A.x * B.x + A.y * B.y;\n}\n\nfunction normalize(x,y)\n{\n let length = Math.sqrt(x * x + y * y)\n return {\n x: x / length,\n y: y / length\n }\n}\n\nfunction transformRect(center, transform, rect)\n{\n if (transform.x < rect.left + rect.width && transform.y < rect.top + rect.height &&\n transform.x > rect.left && transform.y > rect.top) return transform;\n let Len_X = center.x - transform.x;\n let Len_Y = center.y - transform.y;\n\n function angle(Len_X, Len_Y)\n {\n return Math.acos(dot({\n x: 0,\n y: 1\n }, normalize(Len_X, Len_Y))) * 180 / Math.PI\n }\n\n let angleTarget = angle(Len_X, Len_Y);\n if (transform.x < center.x) angleTarget = 360 - angleTarget;\n let angleLeftTop = 360 - angle(rect.left - center.x, (rect.top - center.y) * -1);\n let angleLeftBottom = 360 - angle(rect.left - center.x, (rect.top + rect.height - center.y) * -1);\n let angleRightTop = angle(rect.left + rect.width - center.x, (rect.top - center.y) * -1);\n let angleRightBottom = angle(rect.left + rect.width - center.x, (rect.top + rect.height - center.y) * -1);\n let scale = Len_Y / Len_X;\n let res = {};\n\n if (angleTarget < angleRightTop) {\n let y3 = rect.top - center.y;\n let x3 = y3 / scale;\n res = {\n y: center.y + y3,\n x: center.x + x3\n }\n } else if(angleTarget < angleRightBottom) {\n let x3 = rect.left + rect.width - center.x;\n let y3 = x3 * scale;\n res = {\n y: center.y + y3,\n x: center.x + x3\n }\n } else if (angleTarget < angleLeftBottom) {\n let y3 = rect.top + rect.height - center.y;\n let x3 = y3 / scale;\n res = {\n y: center.y + y3,\n x: center.x + x3\n }\n } else if (angleTarget < angleLeftTop) {\n let x3 = center.x - rect.left;\n let y3 = x3 * scale;\n res = {\n y: center.y - y3,\n x: center.x - x3\n }\n } else {\n let y3 = rect.top - center.y;\n let x3 = y3 / scale;\n res = {\n y: center.y + y3,\n x: center.x + x3\n }\n }\n\n return res;\n}\n\nfunction modelTurnHead(event)\n{\n drag = true;\n\n let rect = canvas.getBoundingClientRect();\n\n let sx = transformScreenX(event.clientX - rect.left);\n let sy = transformScreenY(event.clientY - rect.top);\n let target = transformRect({\n x: rect.left + rect.width / 2,\n y: rect.top + rect.height * headPos\n }, {\n x: event.clientX,\n y: event.clientY\n }, rect)\n let vx = transformViewX(target.x - rect.left);\n let vy = transformViewY(target.y - rect.top);\n\n if (cDefine.DEBUG_MOUSE_LOG)\n console.log(\"modelTurnHead onMouseMove device( x:\" + event.clientX + \" y:\" + event.clientY + \" ) view( x:\" + vx + \" y:\" + vy + \")\");\n\n lastMouseX = sx;\n lastMouseY = sy;\n\n dragMgr.setPoint(vx, vy);\n}\n\nfunction modelTapEvent(event)\n{\n drag = true;\n\n let rect = canvas.getBoundingClientRect();\n\n let sx = transformScreenX(event.clientX - rect.left);\n let sy = transformScreenY(event.clientY - rect.top);\n let target = transformRect({\n x: rect.left + rect.width / 2,\n y: rect.top + rect.height * headPos\n }, {\n x: event.clientX,\n y: event.clientY\n }, rect)\n let vx = transformViewX(target.x - rect.left);\n let vy = transformViewY(target.y - rect.top);\n\n if (cDefine.DEBUG_MOUSE_LOG)\n console.log(\"modelTapEvent onMouseDown device( x:\" + event.clientX + \" y:\" + event.clientY + \" ) view( x:\" + vx + \" y:\" + vy + \")\");\n\n lastMouseX = sx;\n lastMouseY = sy;\n\n live2DMgr.tapEvent(vx, vy);\n}\n\nfunction followPointer(event)\n{\n let rect = canvas.getBoundingClientRect();\n\n let sx = transformScreenX(event.clientX - rect.left);\n let sy = transformScreenY(event.clientY - rect.top);\n\n // log but seems ok\n // console.log(\"ecx=\" + event.clientX + \" ecy=\" + event.clientY + \" sx=\" + sx + \" sy=\" + sy);\n\n let target = transformRect({// seems ok here\n x: rect.left + rect.width / 2,\n y: rect.top + rect.height * headPos\n }, {\n x: event.clientX,\n y: event.clientY\n }, rect)\n let vx = transformViewX(target.x - rect.left);\n let vy = transformViewY(target.y - rect.top);\n\n if (cDefine.DEBUG_MOUSE_LOG)\n console.log(\"followPointer onMouseMove device( x:\" + event.clientX + \" y:\" + event.clientY + \" ) view( x:\" + vx + \" y:\" + vy + \")\");\n\n if (drag)\n {\n lastMouseX = sx;\n lastMouseY = sy;\n dragMgr.setPoint(vx, vy);\n }\n}\n\nfunction lookFront()\n{\n if (drag) {\n drag = false;\n }\n dragMgr.setPoint(0, 0);\n}\n\nfunction mouseEvent(e)\n{\n //e.preventDefault();\n if (e.type == \"mousedown\") {\n modelTapEvent(e);\n } else if (e.type == \"mousemove\") {\n modelTurnHead(e);\n } else if (e.type == \"mouseup\") {\n if(\"button\" in e && e.button != 0) return;\n // lookFront();\n } else if (e.type == \"mouseleave\") {\n lookFront();\n }\n}\n\nfunction touchEvent(e)\n{\n var touch = e.touches[0];\n if (e.type == \"touchstart\") {\n if (e.touches.length == 1) modelTapEvent(touch);\n // onClick(touch);\n } else if (e.type == \"touchmove\") {\n followPointer(touch);\n } else if (e.type == \"touchend\") {\n lookFront();\n }\n}\n\nfunction transformViewX(deviceX)\n{\n var screenX = deviceToScreen.transformX(deviceX);\n return viewMatrix.invertTransformX(screenX);\n}\n\n\nfunction transformViewY(deviceY)\n{\n var screenY = deviceToScreen.transformY(deviceY);\n return viewMatrix.invertTransformY(screenY);\n}\n\n\nfunction transformScreenX(deviceX)\n{\n return deviceToScreen.transformX(deviceX);\n}\n\n\nfunction transformScreenY(deviceY)\n{\n return deviceToScreen.transformY(deviceY);\n}\n\nfunction getWebGLContext()\n{\n var NAMES = [ \"webgl\" , \"experimental-webgl\" , \"webkit-3d\" , \"moz-webgl\"];\n for( var i = 0; i < NAMES.length; i++ ){\n try{\n var ctx = canvas.getContext(NAMES[i], {premultipliedAlpha : true});\n if(ctx) return ctx;\n }\n catch(e){}\n }\n return null;\n};\n",
@@ -8349,7 +8332,7 @@
"lineNumber": 1
},
{
- "__docId__": 315,
+ "__docId__": 314,
"kind": "function",
"name": "_cLive2DApp",
"memberof": "src/_cLive2DApp.js",
@@ -8368,7 +8351,7 @@
"return": null
},
{
- "__docId__": 316,
+ "__docId__": 315,
"kind": "function",
"name": "init",
"memberof": "src/_cLive2DApp.js",
@@ -8395,7 +8378,7 @@
"ignore": true
},
{
- "__docId__": 317,
+ "__docId__": 316,
"kind": "function",
"name": "startDraw",
"memberof": "src/_cLive2DApp.js",
@@ -8415,7 +8398,7 @@
"ignore": true
},
{
- "__docId__": 318,
+ "__docId__": 317,
"kind": "function",
"name": "draw",
"memberof": "src/_cLive2DApp.js",
@@ -8435,7 +8418,7 @@
"ignore": true
},
{
- "__docId__": 319,
+ "__docId__": 318,
"kind": "function",
"name": "changeModel",
"memberof": "src/_cLive2DApp.js",
@@ -8462,7 +8445,7 @@
"ignore": true
},
{
- "__docId__": 320,
+ "__docId__": 319,
"kind": "function",
"name": "modelScaling",
"memberof": "src/_cLive2DApp.js",
@@ -8489,7 +8472,7 @@
"ignore": true
},
{
- "__docId__": 321,
+ "__docId__": 320,
"kind": "function",
"name": "dot",
"memberof": "src/_cLive2DApp.js",
@@ -8526,7 +8509,7 @@
"ignore": true
},
{
- "__docId__": 322,
+ "__docId__": 321,
"kind": "function",
"name": "normalize",
"memberof": "src/_cLive2DApp.js",
@@ -8563,7 +8546,7 @@
"ignore": true
},
{
- "__docId__": 323,
+ "__docId__": 322,
"kind": "function",
"name": "transformRect",
"memberof": "src/_cLive2DApp.js",
@@ -8606,7 +8589,7 @@
"ignore": true
},
{
- "__docId__": 324,
+ "__docId__": 323,
"kind": "function",
"name": "modelTurnHead",
"memberof": "src/_cLive2DApp.js",
@@ -8633,7 +8616,7 @@
"ignore": true
},
{
- "__docId__": 325,
+ "__docId__": 324,
"kind": "function",
"name": "modelTapEvent",
"memberof": "src/_cLive2DApp.js",
@@ -8660,7 +8643,7 @@
"ignore": true
},
{
- "__docId__": 326,
+ "__docId__": 325,
"kind": "function",
"name": "followPointer",
"memberof": "src/_cLive2DApp.js",
@@ -8687,7 +8670,7 @@
"ignore": true
},
{
- "__docId__": 327,
+ "__docId__": 326,
"kind": "function",
"name": "lookFront",
"memberof": "src/_cLive2DApp.js",
@@ -8707,7 +8690,7 @@
"ignore": true
},
{
- "__docId__": 328,
+ "__docId__": 327,
"kind": "function",
"name": "mouseEvent",
"memberof": "src/_cLive2DApp.js",
@@ -8734,7 +8717,7 @@
"ignore": true
},
{
- "__docId__": 329,
+ "__docId__": 328,
"kind": "function",
"name": "touchEvent",
"memberof": "src/_cLive2DApp.js",
@@ -8761,7 +8744,7 @@
"ignore": true
},
{
- "__docId__": 330,
+ "__docId__": 329,
"kind": "function",
"name": "transformViewX",
"memberof": "src/_cLive2DApp.js",
@@ -8792,7 +8775,7 @@
"ignore": true
},
{
- "__docId__": 331,
+ "__docId__": 330,
"kind": "function",
"name": "transformViewY",
"memberof": "src/_cLive2DApp.js",
@@ -8823,7 +8806,7 @@
"ignore": true
},
{
- "__docId__": 332,
+ "__docId__": 331,
"kind": "function",
"name": "transformScreenX",
"memberof": "src/_cLive2DApp.js",
@@ -8854,7 +8837,7 @@
"ignore": true
},
{
- "__docId__": 333,
+ "__docId__": 332,
"kind": "function",
"name": "transformScreenY",
"memberof": "src/_cLive2DApp.js",
@@ -8885,7 +8868,7 @@
"ignore": true
},
{
- "__docId__": 334,
+ "__docId__": 333,
"kind": "function",
"name": "getWebGLContext",
"memberof": "src/_cLive2DApp.js",
@@ -8909,7 +8892,7 @@
"ignore": true
},
{
- "__docId__": 335,
+ "__docId__": 334,
"kind": "file",
"name": "src/_cManager.js",
"content": "import { Live2DFramework } from \"./lib/Live2DFramework\";\nimport PlatformManager from \"./lib/PlatformManager\";\nimport { cModel } from \"./cModel\";\nimport { cDefine } from \"./cDefine\";\n\nexport default function cManager() {\n // console.log(\"--> cManager()\");\n\n this.models = [];\n this.count = -1;\n this.reloadFlg = false;\n\n Live2D.init();\n Live2DFramework.setPlatformManager(new PlatformManager);\n\n}\n\ncManager.prototype.createModel = function () {\n\n var model = new cModel();\n this.models.push(model);\n\n return model;\n\n}\n\n\ncManager.prototype.changeModel = function (gl, modelurl) {\n // console.log(\"--> cManager.update(gl)\");\n\n if (this.reloadFlg) {\n this.reloadFlg = false;\n this.releaseModel(0, gl);\n this.createModel();\n this.models[0].load(gl, modelurl);\n }\n\n};\n\n\ncManager.prototype.getModel = function (no) {\n // console.log(\"--> cManager.getModel(\" + no + \")\");\n\n if (no >= this.models.length) return null;\n\n return this.models[no];\n};\n\n\n\ncManager.prototype.releaseModel = function (no, gl) {\n // console.log(\"--> cManager.releaseModel(\" + no + \")\");\n\n if (this.models.length <= no) return;\n\n this.models[no].release(gl);\n\n delete this.models[no];\n this.models.splice(no, 1);\n};\n\n\n\ncManager.prototype.numModels = function () {\n return this.models.length;\n};\n\n\n\ncManager.prototype.setDrag = function (x, y) {\n for (var i = 0; i < this.models.length; i++) {\n this.models[i].setDrag(x, y);\n }\n}\n\ncManager.prototype.tapEvent = function (x, y) {\n if (cDefine.DEBUG_LOG)\n console.log(\"tapEvent view x:\" + x + \" y:\" + y);\n\n for (var i = 0; i < this.models.length; i++) {\n\n if (this.models[i].hitTest(cDefine.HIT_AREA_HEAD, x, y)) {\n\n if (cDefine.DEBUG_LOG)\n console.log(\"Tap face.\");\n\n this.models[i].setRandomExpression();\n }\n else if (this.models[i].hitTest(cDefine.HIT_AREA_BODY, x, y)) {\n\n if (cDefine.DEBUG_LOG)\n console.log(\"Tap body.\" + \" models[\" + i + \"]\");\n\n this.models[i].startRandomMotion(cDefine.MOTION_GROUP_TAP_BODY,\n cDefine.PRIORITY_NORMAL);\n }\n }\n\n return true;\n};\n",
@@ -8920,7 +8903,7 @@
"lineNumber": 1
},
{
- "__docId__": 336,
+ "__docId__": 335,
"kind": "function",
"name": "cManager",
"memberof": "src/_cManager.js",
@@ -8939,7 +8922,7 @@
"return": null
},
{
- "__docId__": 337,
+ "__docId__": 336,
"kind": "function",
"name": "createModel",
"memberof": "src/_cManager.js",
@@ -8963,7 +8946,7 @@
"ignore": true
},
{
- "__docId__": 338,
+ "__docId__": 337,
"kind": "function",
"name": "changeModel",
"memberof": "src/_cManager.js",
@@ -8996,7 +8979,7 @@
"ignore": true
},
{
- "__docId__": 339,
+ "__docId__": 338,
"kind": "function",
"name": "getModel",
"memberof": "src/_cManager.js",
@@ -9027,7 +9010,7 @@
"ignore": true
},
{
- "__docId__": 340,
+ "__docId__": 339,
"kind": "function",
"name": "releaseModel",
"memberof": "src/_cManager.js",
@@ -9060,7 +9043,7 @@
"ignore": true
},
{
- "__docId__": 341,
+ "__docId__": 340,
"kind": "function",
"name": "numModels",
"memberof": "src/_cManager.js",
@@ -9084,7 +9067,7 @@
"ignore": true
},
{
- "__docId__": 342,
+ "__docId__": 341,
"kind": "function",
"name": "setDrag",
"memberof": "src/_cManager.js",
@@ -9117,7 +9100,7 @@
"ignore": true
},
{
- "__docId__": 343,
+ "__docId__": 342,
"kind": "function",
"name": "tapEvent",
"memberof": "src/_cManager.js",
@@ -9154,7 +9137,7 @@
"ignore": true
},
{
- "__docId__": 344,
+ "__docId__": 343,
"kind": "file",
"name": "src/_cModel.js",
"content": "import { Live2DFramework, L2DBaseModel, L2DEyeBlink } from \"./lib/Live2DFramework\";\nimport { ModelSettingJson } from \"./utils/ModelSettingJson\";\nimport { MatrixStack } from \"./utils/MatrixStack\";\nimport { cDefine } from \"./cDefine\";\n\n//============================================================\n//============================================================\n// class cModel extends L2DBaseModel\n//============================================================\n//============================================================\nexport default function cModel()\n{\n //L2DBaseModel.apply(this, arguments);\n L2DBaseModel.prototype.constructor.call(this);\n\n this.modelHomeDir = \"\";\n this.modelSetting = null;\n this.tmpMatrix = [];\n}\n\ncModel.prototype = new L2DBaseModel();\n\n\ncModel.prototype.load = function(gl, modelSettingPath, callback)\n{\n this.setUpdating(true);\n this.setInitialized(false);\n\n this.modelHomeDir = modelSettingPath.substring(0, modelSettingPath.lastIndexOf(\"/\") + 1);\n\n this.modelSetting = new ModelSettingJson();\n\n var thisRef = this;\n\n this.modelSetting.loadModelSetting(modelSettingPath, function(){\n\n var path = thisRef.modelHomeDir + thisRef.modelSetting.getModelFile();\n thisRef.loadModelData(path, function(model){\n\n for (var i = 0; i < thisRef.modelSetting.getTextureNum(); i++)\n {\n\n var texPaths = thisRef.modelHomeDir +\n thisRef.modelSetting.getTextureFile(i);\n\n thisRef.loadTexture(i, texPaths, function() {\n\n if( thisRef.isTexLoaded ) {\n\n if (thisRef.modelSetting.getExpressionNum() > 0)\n {\n\n thisRef.expressions = {};\n\n for (var j = 0; j < thisRef.modelSetting.getExpressionNum(); j++)\n {\n var expName = thisRef.modelSetting.getExpressionName(j);\n var expFilePath = thisRef.modelHomeDir +\n thisRef.modelSetting.getExpressionFile(j);\n\n thisRef.loadExpression(expName, expFilePath);\n }\n }\n else\n {\n thisRef.expressionManager = null;\n thisRef.expressions = {};\n }\n\n\n\n if (thisRef.eyeBlink == null)\n {\n thisRef.eyeBlink = new L2DEyeBlink();\n }\n\n\n if (thisRef.modelSetting.getPhysicsFile() != null)\n {\n thisRef.loadPhysics(thisRef.modelHomeDir +\n thisRef.modelSetting.getPhysicsFile());\n }\n else\n {\n thisRef.physics = null;\n }\n\n\n\n if (thisRef.modelSetting.getPoseFile() != null)\n {\n thisRef.loadPose(\n thisRef.modelHomeDir +\n thisRef.modelSetting.getPoseFile(),\n function() {\n thisRef.pose.updateParam(thisRef.live2DModel);\n }\n );\n }\n else\n {\n thisRef.pose = null;\n }\n\n\n\n if (thisRef.modelSetting.getLayout() != null)\n {\n var layout = thisRef.modelSetting.getLayout();\n if (layout[\"width\"] != null)\n thisRef.modelMatrix.setWidth(layout[\"width\"]);\n if (layout[\"height\"] != null)\n thisRef.modelMatrix.setHeight(layout[\"height\"]);\n\n if (layout[\"x\"] != null)\n thisRef.modelMatrix.setX(layout[\"x\"]);\n if (layout[\"y\"] != null)\n thisRef.modelMatrix.setY(layout[\"y\"]);\n if (layout[\"center_x\"] != null)\n thisRef.modelMatrix.centerX(layout[\"center_x\"]);\n if (layout[\"center_y\"] != null)\n thisRef.modelMatrix.centerY(layout[\"center_y\"]);\n if (layout[\"top\"] != null)\n thisRef.modelMatrix.top(layout[\"top\"]);\n if (layout[\"bottom\"] != null)\n thisRef.modelMatrix.bottom(layout[\"bottom\"]);\n if (layout[\"left\"] != null)\n thisRef.modelMatrix.left(layout[\"left\"]);\n if (layout[\"right\"] != null)\n thisRef.modelMatrix.right(layout[\"right\"]);\n }\n\n for (var j = 0; j < thisRef.modelSetting.getInitParamNum(); j++)\n {\n\n thisRef.live2DModel.setParamFloat(\n thisRef.modelSetting.getInitParamID(j),\n thisRef.modelSetting.getInitParamValue(j)\n );\n }\n\n for (var j = 0; j < thisRef.modelSetting.getInitPartsVisibleNum(); j++)\n {\n\n thisRef.live2DModel.setPartsOpacity(\n thisRef.modelSetting.getInitPartsVisibleID(j),\n thisRef.modelSetting.getInitPartsVisibleValue(j)\n );\n }\n\n\n\n thisRef.live2DModel.saveParam();\n // thisRef.live2DModel.setGL(gl);\n\n\n thisRef.preloadMotionGroup(cDefine.MOTION_GROUP_IDLE);\n thisRef.mainMotionManager.stopAllMotions();\n\n thisRef.setUpdating(false);\n thisRef.setInitialized(true);\n\n if (typeof callback == \"function\") callback();\n\n }\n });\n }\n });\n });\n};\n\n\n\ncModel.prototype.release = function(gl)\n{\n // this.live2DModel.deleteTextures();\n var pm = Live2DFramework.getPlatformManager();\n\n gl.deleteTexture(pm.texture);\n}\n\n\n\ncModel.prototype.preloadMotionGroup = function(name)\n{\n var thisRef = this;\n\n for (var i = 0; i < this.modelSetting.getMotionNum(name); i++)\n {\n var file = this.modelSetting.getMotionFile(name, i);\n this.loadMotion(file, this.modelHomeDir + file, function(motion) {\n motion.setFadeIn(thisRef.modelSetting.getMotionFadeIn(name, i));\n motion.setFadeOut(thisRef.modelSetting.getMotionFadeOut(name, i));\n });\n\n }\n}\n\n\ncModel.prototype.update = function()\n{\n // console.log(\"--> cModel.update()\");\n\n if(this.live2DModel == null)\n {\n if (cDefine.DEBUG_LOG) console.error(\"Failed to update.\");\n\n return;\n }\n\n var timeMSec = UtSystem.getUserTimeMSec() - this.startTimeMSec;\n var timeSec = timeMSec / 1000.0;\n var t = timeSec * 2 * Math.PI;\n\n\n if (this.mainMotionManager.isFinished())\n {\n\n this.startRandomMotion(cDefine.MOTION_GROUP_IDLE, cDefine.PRIORITY_IDLE);\n }\n\n //-----------------------------------------------------------------\n\n\n this.live2DModel.loadParam();\n\n\n\n var update = this.mainMotionManager.updateParam(this.live2DModel);\n if (!update) {\n\n if(this.eyeBlink != null) {\n this.eyeBlink.updateParam(this.live2DModel);\n }\n }\n\n\n this.live2DModel.saveParam();\n\n //-----------------------------------------------------------------\n\n\n if (this.expressionManager != null &&\n this.expressions != null &&\n !this.expressionManager.isFinished())\n {\n this.expressionManager.updateParam(this.live2DModel);\n }\n\n\n\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_X\", this.dragX * 30, 1);\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_Y\", this.dragY * 30, 1);\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_Z\", (this.dragX * this.dragY) * -30, 1);\n\n\n\n this.live2DModel.addToParamFloat(\"PARAM_BODY_ANGLE_X\", this.dragX*10, 1);\n\n\n\n this.live2DModel.addToParamFloat(\"PARAM_EYE_BALL_X\", this.dragX, 1);\n this.live2DModel.addToParamFloat(\"PARAM_EYE_BALL_Y\", this.dragY, 1);\n\n\n\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_X\",\n Number((15 * Math.sin(t / 6.5345))), 0.5);\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_Y\",\n Number((8 * Math.sin(t / 3.5345))), 0.5);\n this.live2DModel.addToParamFloat(\"PARAM_ANGLE_Z\",\n Number((10 * Math.sin(t / 5.5345))), 0.5);\n this.live2DModel.addToParamFloat(\"PARAM_BODY_ANGLE_X\",\n Number((4 * Math.sin(t / 15.5345))), 0.5);\n this.live2DModel.setParamFloat(\"PARAM_BREATH\",\n Number((0.5 + 0.5 * Math.sin(t / 3.2345))), 1);\n\n\n if (this.physics != null)\n {\n this.physics.updateParam(this.live2DModel);\n }\n\n\n if (this.lipSync == null)\n {\n this.live2DModel.setParamFloat(\"PARAM_MOUTH_OPEN_Y\",\n this.lipSyncValue);\n }\n\n\n if( this.pose != null ) {\n this.pose.updateParam(this.live2DModel);\n }\n\n this.live2DModel.update();\n};\n\n\n\ncModel.prototype.setRandomExpression = function()\n{\n var tmp = [];\n for (var name in this.expressions)\n {\n tmp.push(name);\n }\n\n var no = parseInt(Math.random() * tmp.length);\n\n this.setExpression(tmp[no]);\n}\n\n\n\ncModel.prototype.startRandomMotion = function(name, priority)\n{\n var max = this.modelSetting.getMotionNum(name);\n var no = parseInt(Math.random() * max);\n this.startMotion(name, no, priority);\n}\n\n\n\ncModel.prototype.startMotion = function(name, no, priority)\n{\n // console.log(\"startMotion : \" + name + \" \" + no + \" \" + priority);\n\n var motionName = this.modelSetting.getMotionFile(name, no);\n\n if (motionName == null || motionName == \"\")\n {\n if (cDefine.DEBUG_LOG)\n console.error(\"Failed to motion.\");\n return;\n }\n\n if (priority == cDefine.PRIORITY_FORCE)\n {\n this.mainMotionManager.setReservePriority(priority);\n }\n else if (!this.mainMotionManager.reserveMotion(priority))\n {\n if (cDefine.DEBUG_LOG)\n console.log(\"Motion is running.\")\n return;\n }\n\n var thisRef = this;\n var motion;\n\n if (this.motions[name] == null)\n {\n this.loadMotion(null, this.modelHomeDir + motionName, function(mtn) {\n motion = mtn;\n\n\n thisRef.setFadeInFadeOut(name, no, priority, motion);\n\n });\n }\n else\n {\n motion = this.motions[name];\n\n\n thisRef.setFadeInFadeOut(name, no, priority, motion);\n }\n}\n\n\ncModel.prototype.setFadeInFadeOut = function(name, no, priority, motion)\n{\n var motionName = this.modelSetting.getMotionFile(name, no);\n\n motion.setFadeIn(this.modelSetting.getMotionFadeIn(name, no));\n motion.setFadeOut(this.modelSetting.getMotionFadeOut(name, no));\n\n\n if (cDefine.DEBUG_LOG)\n console.log(\"Start motion : \" + motionName);\n\n if (this.modelSetting.getMotionSound(name, no) == null)\n {\n this.mainMotionManager.startMotionPrio(motion, priority);\n }\n else\n {\n var soundName = this.modelSetting.getMotionSound(name, no);\n // var player = new Sound(this.modelHomeDir + soundName);\n\n var snd = document.createElement(\"audio\");\n snd.src = this.modelHomeDir + soundName;\n\n if (cDefine.DEBUG_LOG)\n console.log(\"Start sound : \" + soundName);\n\n snd.play();\n this.mainMotionManager.startMotionPrio(motion, priority);\n }\n}\n\n\n\ncModel.prototype.setExpression = function(name)\n{\n var motion = this.expressions[name];\n\n if (cDefine.DEBUG_LOG)\n console.log(\"Expression : \" + name);\n\n this.expressionManager.startMotion(motion, false);\n}\n\n\n\ncModel.prototype.draw = function(gl)\n{\n //console.log(\"--> cModel.draw()\");\n\n // if(this.live2DModel == null) return;\n\n\n MatrixStack.push();\n\n MatrixStack.multMatrix(this.modelMatrix.getArray());\n\n this.tmpMatrix = MatrixStack.getMatrix()\n this.live2DModel.setMatrix(this.tmpMatrix);\n this.live2DModel.draw();\n\n MatrixStack.pop();\n\n};\n\n\n\ncModel.prototype.hitTest = function(id, testX, testY)\n{\n var len = this.modelSetting.getHitAreaNum();\n for (var i = 0; i < len; i++)\n {\n if (id == this.modelSetting.getHitAreaName(i))\n {\n var drawID = this.modelSetting.getHitAreaID(i);\n\n return this.hitTestSimple(drawID, testX, testY);\n }\n }\n\n return false;\n}\n",
@@ -9165,7 +9148,7 @@
"lineNumber": 1
},
{
- "__docId__": 345,
+ "__docId__": 344,
"kind": "function",
"name": "cModel",
"memberof": "src/_cModel.js",
@@ -9184,7 +9167,7 @@
"return": null
},
{
- "__docId__": 346,
+ "__docId__": 345,
"kind": "function",
"name": "load",
"memberof": "src/_cModel.js",
@@ -9223,7 +9206,7 @@
"ignore": true
},
{
- "__docId__": 347,
+ "__docId__": 346,
"kind": "function",
"name": "release",
"memberof": "src/_cModel.js",
@@ -9250,7 +9233,7 @@
"ignore": true
},
{
- "__docId__": 348,
+ "__docId__": 347,
"kind": "function",
"name": "preloadMotionGroup",
"memberof": "src/_cModel.js",
@@ -9277,7 +9260,7 @@
"ignore": true
},
{
- "__docId__": 349,
+ "__docId__": 348,
"kind": "function",
"name": "update",
"memberof": "src/_cModel.js",
@@ -9297,7 +9280,7 @@
"ignore": true
},
{
- "__docId__": 350,
+ "__docId__": 349,
"kind": "function",
"name": "setRandomExpression",
"memberof": "src/_cModel.js",
@@ -9317,7 +9300,7 @@
"ignore": true
},
{
- "__docId__": 351,
+ "__docId__": 350,
"kind": "function",
"name": "startRandomMotion",
"memberof": "src/_cModel.js",
@@ -9350,7 +9333,7 @@
"ignore": true
},
{
- "__docId__": 352,
+ "__docId__": 351,
"kind": "function",
"name": "startMotion",
"memberof": "src/_cModel.js",
@@ -9389,7 +9372,7 @@
"ignore": true
},
{
- "__docId__": 353,
+ "__docId__": 352,
"kind": "function",
"name": "setFadeInFadeOut",
"memberof": "src/_cModel.js",
@@ -9434,7 +9417,7 @@
"ignore": true
},
{
- "__docId__": 354,
+ "__docId__": 353,
"kind": "function",
"name": "setExpression",
"memberof": "src/_cModel.js",
@@ -9461,7 +9444,7 @@
"ignore": true
},
{
- "__docId__": 355,
+ "__docId__": 354,
"kind": "function",
"name": "draw",
"memberof": "src/_cModel.js",
@@ -9488,7 +9471,7 @@
"ignore": true
},
{
- "__docId__": 356,
+ "__docId__": 355,
"kind": "function",
"name": "hitTest",
"memberof": "src/_cModel.js",
@@ -9531,7 +9514,7 @@
"ignore": true
},
{
- "__docId__": 357,
+ "__docId__": 356,
"kind": "file",
"name": "src/_PlatformManager.js",
"content": "\n/**\n *\n * You can modify and use this source freely\n * only for the development of application related Live2D.\n *\n * (c) Live2D Inc. All rights reserved.\n */\n\n// Modified by xiazeyu.\n\n/**\n* @desc A library that provide basic IO and json function\n*/\n\n\nimport { getContext } from \"./webGLContext\";\nimport { Live2DModelWebGL } from \"./live2d.core\";\n\n\n//============================================================\n//============================================================\n// class PlatformManager extend IPlatformManager\n//============================================================\n//============================================================\n\n/**\n* @name PlatformManager\n* @desc Define the variable type of PlatformManager\n* @param null\n* @returns {Structure} PlatformManager\n*/\nexport default function PlatformManager()\n{\n\n}\n\n\n//============================================================\n// PlatformManager # loadBytes()\n//============================================================\n\n/**\n* @name loadBytes\n* @desc load bytes from the path and callback\n* @param {String} path, {Function} callback\n* @returns callback {raw} context\n* @memberOf PlatformManager\n*/\n\nPlatformManager.prototype.loadBytes = function(path/*String*/, callback)\n{\n var request = new XMLHttpRequest();\n request.open(\"GET\", path, true);\n request.responseType = \"arraybuffer\";\n request.onload = function(){\n switch(request.status){\n case 200:\n callback(request.response);\n break;\n default:\n console.error(\"Failed to load (\" + request.status + \") : \" + path);\n break;\n }\n }\n request.send(null);\n // return request;\n}\n\n\n//============================================================\n// PlatformManager # loadString()\n//============================================================\n\n/**\n* @name loadString\n* @desc load bytes from the path and put it into buffer\n* @param {String} path\n* @returns buffer {raw} context\n* @memberOf PlatformManager\n*/\nPlatformManager.prototype.loadString = function(path/*String*/)\n{\n\n this.loadBytes(path, function(buf) {\n return buf;\n });\n\n}\n\n\n//============================================================\n// PlatformManager # loadLive2DModel()\n//============================================================\n\n/**\n* @name loadLive2DModel\n* @desc load Live2DModel from the path and put it into buffer\n* @param {String} path, {function} callback\n* @returns callback loaded model\n* @memberOf PlatformManager\n*/\nPlatformManager.prototype.loadLive2DModel = function(path/*String*/, callback)\n{\n var model = null;\n\n // load moc\n this.loadBytes(path, function(buf){\n model = Live2DModelWebGL.loadModel(buf);\n callback(model);\n });\n\n}\n\n\n//============================================================\n// PlatformManager # loadTexture()\n//============================================================\n\n/**\n* @name loadTexture\n* @desc load Live2DModel's Texture and callback\n* @param {Live2DModelWebGL}model, {int}no, {string}path, {function}callback\n* @returns callback\n* @memberOf PlatformManager\n*/\nPlatformManager.prototype.loadTexture = function(model/*ALive2DModel*/, no/*int*/, path/*String*/, callback)\n{\n // load textures\n var loadedImage = new Image();\n loadedImage.src = path;\n loadedImage.onload = onload;\n loadedImage.onerror = onerror;\n\n // var thisRef = this;\n loadedImage.onload = function() {\n // create texture\n var gl = getContext();\n var texture = gl.createTexture();\n if (!texture){ console.error(\"Failed to generate gl texture name.\"); return -1; }\n\n if(!model.isPremultipliedAlpha()){\n // 乗算済アルファテクスチャ以外の場合\n // emmmm, maybe do something for textures with alpha layer.\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, 1);\n }\n gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, 1);\n gl.activeTexture(gl.TEXTURE0);\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA,\n gl.UNSIGNED_BYTE, loadedImage);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_NEAREST);\n gl.generateMipmap(gl.TEXTURE_2D);\n\n\n\n model.setTexture(no, texture);\n\n // テクスチャオブジェクトを解放\n // Release the texture object to prevent buffer overruns.\n texture = null;\n\n if (typeof callback == \"function\") callback();\n };\n\n loadedImage.onerror = function() {\n console.error(\"Failed to load image : \" + path);\n }\n}\n\n\n//============================================================\n// PlatformManager # parseFromBytes(buf)\n\n//============================================================\n\n/**\n* @name jsonParseFromBytes\n* @desc parse json file into arrays\n* @param {raw} buf\n* @returns {Array}jsonObj\n* @memberOf PlatformManager\n*/\nPlatformManager.prototype.jsonParseFromBytes = function(buf){\n\n var jsonStr;\n var bomCode = new Uint8Array(buf, 0, 3);\n if (bomCode[0] == 239 && bomCode[1] == 187 && bomCode[2] == 191) {\n jsonStr = String.fromCharCode.apply(null, new Uint8Array(buf, 3));\n } else {\n jsonStr = String.fromCharCode.apply(null, new Uint8Array(buf));\n }\n\n var jsonObj = JSON.parse(jsonStr);\n\n return jsonObj;\n};\n\n\n\n//============================================================\n// PlatformManager # log()\n//============================================================\n\n/**\n* @name log\n* @desc output log in console\n* @param {string} txt\n* @returns null\n* @memberOf PlatformManager\n*/\nPlatformManager.prototype.log = function(txt/*String*/)\n{\n console.log(txt);\n}\n",
@@ -9542,7 +9525,7 @@
"lineNumber": 1
},
{
- "__docId__": 358,
+ "__docId__": 357,
"kind": "function",
"name": "PlatformManager",
"memberof": "src/_PlatformManager.js",
@@ -9584,7 +9567,7 @@
}
},
{
- "__docId__": 359,
+ "__docId__": 358,
"kind": "function",
"name": "loadBytes",
"memberof": "src/_PlatformManager.js",
@@ -9631,7 +9614,7 @@
"ignore": true
},
{
- "__docId__": 360,
+ "__docId__": 359,
"kind": "function",
"name": "loadString",
"memberof": "src/_PlatformManager.js",
@@ -9678,7 +9661,7 @@
"ignore": true
},
{
- "__docId__": 361,
+ "__docId__": 360,
"kind": "function",
"name": "loadLive2DModel",
"memberof": "src/_PlatformManager.js",
@@ -9725,7 +9708,7 @@
"ignore": true
},
{
- "__docId__": 362,
+ "__docId__": 361,
"kind": "function",
"name": "loadTexture",
"memberof": "src/_PlatformManager.js",
@@ -9772,7 +9755,7 @@
"ignore": true
},
{
- "__docId__": 363,
+ "__docId__": 362,
"kind": "function",
"name": "jsonParseFromBytes",
"memberof": "src/_PlatformManager.js",
@@ -9819,7 +9802,7 @@
"ignore": true
},
{
- "__docId__": 364,
+ "__docId__": 363,
"kind": "function",
"name": "log",
"memberof": "src/_PlatformManager.js",
@@ -9866,7 +9849,7 @@
"ignore": true
},
{
- "__docId__": 365,
+ "__docId__": 364,
"kind": "file",
"name": "src/_webglcontext.js",
"content": "// Modified by xiazeyu.\n\n/**\n* @desc A basic storage of webGL context\n*/\n\n\n// Defined a global variable to record the current WebGL context.\nlet context = undefined;\n\n/**\n* @name setContext\n* @desc record the current WebGL context\n* @param {String} msg Message to log\n* @returns {Element} webGL context being captured\n*/\nexport function setContext(webglContext) {\n context = webglContext;\n}\n\n\n/**\n* @name getContext\n* @desc return the current WebGL context\n* @param null\n* @returns {Element} current webGL context\n*/\nexport function getContext() {\n return context;\n}\n",
@@ -9877,7 +9860,7 @@
"lineNumber": 1
},
{
- "__docId__": 366,
+ "__docId__": 365,
"kind": "variable",
"name": "context",
"memberof": "src/_webglcontext.js",
@@ -9897,7 +9880,7 @@
"ignore": true
},
{
- "__docId__": 367,
+ "__docId__": 366,
"kind": "function",
"name": "setContext",
"memberof": "src/_webglcontext.js",
@@ -9939,7 +9922,7 @@
}
},
{
- "__docId__": 368,
+ "__docId__": 367,
"kind": "function",
"name": "getContext",
"memberof": "src/_webglcontext.js",
@@ -9990,7 +9973,7 @@
},
{
"kind": "packageJSON",
- "content": "{\n \"name\": \"live2d-widget\",\n \"version\": \"3.0.0\",\n \"description\": \"Add the Sseexxyyy live2d to webpages.\",\n \"main\": \"index.js\",\n \"scripts\": {\n \"inst:dev\": \"npm install -g webpack&&npm install -g commitizen&&npm install -g cz-conventional-changelog&&npm install -g conventional-changelog-cli&&npm install\",\n \"build:dev\": \"webpack --progress --colors\",\n \"build:prod\": \"webpack --env prod --progress --colors\",\n \"build:doc\": \"./node_modules/.bin/esdoc\",\n \"commit\": \"git pull&&git-cz\",\n \"changelog\": \"git pull&&conventional-changelog -i doc/CHANGELOG.md -r 0 -s -u&&git add doc/CHANGELOG.md&&git commit -m \\\"docs: update CHANGELOG\\\"&&git push&&git status\",\n \"test\": \"echo \\\"Error: no test specified\\\" && exit 1\",\n \"ghpages\": \"push-gh-pages\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/xiazeyu/live2d-widget.js.git\"\n },\n \"author\": \"xiazeyu \",\n \"contributors\": [\n \"xiazeyu \",\n \"EYHN \"\n ],\n \"maintainers\": [\n \"xiazeyu \",\n \"EYHN \"\n ],\n \"license\": \"GPL-2.0\",\n \"bugs\": {\n \"url\": \"https://github.com/xiazeyu/live2d-widget.js/issues\"\n },\n \"homepage\": \"https://github.com/xiazeyu/live2d-widget.js#readme\",\n \"devDependencies\": {\n \"babel-core\": \"^6.26.0\",\n \"babel-loader\": \"^7.1.2\",\n \"babel-plugin-lodash\": \"^3.3.2\",\n \"babel-plugin-syntax-dynamic-import\": \"^6.18.0\",\n \"babel-preset-env\": \"^1.6.1\",\n \"commitizen\": \"^2.9.6\",\n \"current-device\": \"^0.7.2\",\n \"cz-conventional-changelog\": \"^2.1.0\",\n \"esdoc\": \"^1.0.4\",\n \"esdoc-ecmascript-proposal-plugin\": \"^1.0.0\",\n \"esdoc-standard-plugin\": \"^1.0.0\",\n \"html-loader\": \"^0.5.1\",\n \"lodash\": \"^4.17.4\",\n \"lodash-webpack-plugin\": \"^0.11.4\",\n \"path\": \"^0.12.7\",\n \"uglifyjs-webpack-plugin\": \"^1.1.5\",\n \"webpack\": \"^3.10.0\",\n \"webpack-manifest-plugin\": \"^1.3.2\",\n \"webpack-visualizer-plugin\": \"^0.1.11\"\n },\n \"config\": {\n \"commitizen\": {\n \"path\": \"./node_modules/cz-conventional-changelog\"\n }\n }\n}\n",
+ "content": "{\n \"name\": \"live2d-widget\",\n \"version\": \"3.0.0\",\n \"description\": \"Add the Sseexxyyy live2d to webpages.\",\n \"main\": \"index.js\",\n \"scripts\": {\n \"inst:dev\": \"npm install -g webpack&&npm install -g commitizen&&npm install -g cz-conventional-changelog&&npm install -g conventional-changelog-cli&&npm install\",\n \"build:dev\": \"webpack --progress --colors\",\n \"build:prod\": \"webpack --env prod --progress --colors\",\n \"build:doc\": \"./node_modules/.bin/esdoc\",\n \"commit\": \"git pull&&git-cz\",\n \"changelog\": \"git pull&&conventional-changelog -i doc/CHANGELOG.md -r 0 -s -u&&git add doc/CHANGELOG.md&&git commit -m \\\"docs: update CHANGELOG\\\"&&git push&&git status\",\n \"test\": \"echo \\\"Error: no test specified\\\" && exit 1\",\n \"ghpages\": \"push-gh-pages\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/xiazeyu/live2d-widget.js.git\"\n },\n \"author\": \"xiazeyu \",\n \"contributors\": [\n \"xiazeyu \",\n \"EYHN \"\n ],\n \"maintainers\": [\n \"xiazeyu \",\n \"EYHN \"\n ],\n \"license\": \"GPL-2.0\",\n \"bugs\": {\n \"url\": \"https://github.com/xiazeyu/live2d-widget.js/issues\"\n },\n \"homepage\": \"https://github.com/xiazeyu/live2d-widget.js#readme\",\n \"devDependencies\": {\n \"babel-core\": \"^6.26.0\",\n \"babel-loader\": \"^7.1.2\",\n \"babel-plugin-lodash\": \"^3.3.2\",\n \"babel-plugin-syntax-dynamic-import\": \"^6.18.0\",\n \"babel-preset-env\": \"^1.6.1\",\n \"commitizen\": \"^2.9.6\",\n \"core-js\": \"^2.5.3\",\n \"current-device\": \"^0.7.2\",\n \"cz-conventional-changelog\": \"^2.1.0\",\n \"esdoc\": \"^1.0.4\",\n \"esdoc-ecmascript-proposal-plugin\": \"^1.0.0\",\n \"esdoc-standard-plugin\": \"^1.0.0\",\n \"html-loader\": \"^0.5.4\",\n \"lodash\": \"^4.17.4\",\n \"lodash-webpack-plugin\": \"^0.11.4\",\n \"path\": \"^0.12.7\",\n \"uglifyjs-webpack-plugin\": \"^1.1.6\",\n \"webpack\": \"^3.10.0\",\n \"webpack-manifest-plugin\": \"^1.3.2\",\n \"webpack-visualizer-plugin\": \"^0.1.11\"\n },\n \"config\": {\n \"commitizen\": {\n \"path\": \"./node_modules/cz-conventional-changelog\"\n }\n }\n}\n",
"longname": "D:\\git\\live2d-widget.js\\package.json",
"name": "package.json",
"static": true,
diff --git a/ghpages/docs/script/search_index.js b/ghpages/docs/script/search_index.js
index 8d5e982..48611d0 100644
--- a/ghpages/docs/script/search_index.js
+++ b/ghpages/docs/script/search_index.js
@@ -53,6 +53,12 @@ window.esdocSearchIndex = [
"getContext live2d-widget/src/_webglcontext.js",
"function"
],
+ [
+ "live2d-widget/src/wppublicpath.js~getcurrentpath",
+ "function/index.html#static-function-getCurrentPath",
+ "getCurrentPath live2d-widget/src/wpPublicPath.js",
+ "function"
+ ],
[
"live2d-widget/src/index.js~init",
"function/index.html#static-function-init",
diff --git a/ghpages/docs/source.html b/ghpages/docs/source.html
index 4a71e7a..49a63ef 100644
--- a/ghpages/docs/source.html
+++ b/ghpages/docs/source.html
@@ -38,6 +38,7 @@
FgetContext
FsetContext
Finit
+FgetCurrentPath
configFconfigApplyer
FconfigValidater
utilsFModelSettingJson
@@ -45,7 +46,7 @@
-Source
57/305
+
Source
58/304
diff --git a/package-lock.json b/package-lock.json
index 6b29a00..2703382 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -12,9 +12,9 @@
"optional": true
},
"acorn": {
- "version": "5.2.1",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.2.1.tgz",
- "integrity": "sha512-jG0u7c4Ly+3QkkW18V+NRDN+4bWHdln30NL1ZL2AvFZZmQe/BfopYCtghCKKVBUSetZ4QKcyA0pY6/4Gw8Pv8w==",
+ "version": "2.7.0",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-2.7.0.tgz",
+ "integrity": "sha1-q259nYhqrKiwhbwzEreaGYQz8Oc=",
"dev": true
},
"acorn-dynamic-import": {
@@ -42,15 +42,6 @@
"optional": true,
"requires": {
"acorn": "2.7.0"
- },
- "dependencies": {
- "acorn": {
- "version": "2.7.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-2.7.0.tgz",
- "integrity": "sha1-q259nYhqrKiwhbwzEreaGYQz8Oc=",
- "dev": true,
- "optional": true
- }
}
},
"ajv": {
@@ -260,14 +251,6 @@
"private": "0.1.8",
"slash": "1.0.0",
"source-map": "0.5.7"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-generator": {
@@ -284,14 +267,6 @@
"lodash": "4.17.4",
"source-map": "0.5.7",
"trim-right": "1.0.1"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-helper-builder-binary-assignment-operator-visitor": {
@@ -327,14 +302,6 @@
"babel-runtime": "6.26.0",
"babel-types": "6.26.0",
"lodash": "4.17.4"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-helper-explode-assignable-expression": {
@@ -429,14 +396,6 @@
"babel-runtime": "6.26.0",
"babel-types": "6.26.0",
"lodash": "4.17.4"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-helper-remap-async-to-generator": {
@@ -513,7 +472,7 @@
"requires": {
"babel-helper-module-imports": "7.0.0-beta.3",
"babel-types": "6.26.0",
- "glob": "7.1.1",
+ "glob": "7.1.2",
"lodash": "4.17.4",
"require-package-name": "2.0.1"
}
@@ -582,14 +541,6 @@
"babel-traverse": "6.26.0",
"babel-types": "6.26.0",
"lodash": "4.17.4"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-plugin-transform-es2015-classes": {
@@ -858,7 +809,7 @@
"babel-plugin-transform-es2015-unicode-regex": "6.24.1",
"babel-plugin-transform-exponentiation-operator": "6.24.1",
"babel-plugin-transform-regenerator": "6.26.0",
- "browserslist": "2.10.0",
+ "browserslist": "2.11.0",
"invariant": "2.2.2",
"semver": "5.4.1"
}
@@ -876,20 +827,6 @@
"lodash": "4.17.4",
"mkdirp": "0.5.1",
"source-map-support": "0.4.18"
- },
- "dependencies": {
- "core-js": {
- "version": "2.5.3",
- "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.3.tgz",
- "integrity": "sha1-isw4NFgk8W2DZbfJtCWRaOjtYD4=",
- "dev": true
- },
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-runtime": {
@@ -900,14 +837,6 @@
"requires": {
"core-js": "2.5.3",
"regenerator-runtime": "0.11.1"
- },
- "dependencies": {
- "core-js": {
- "version": "2.5.3",
- "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.3.tgz",
- "integrity": "sha1-isw4NFgk8W2DZbfJtCWRaOjtYD4=",
- "dev": true
- }
}
},
"babel-template": {
@@ -921,14 +850,6 @@
"babel-types": "6.26.0",
"babylon": "6.18.0",
"lodash": "4.17.4"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-traverse": {
@@ -946,14 +867,6 @@
"globals": "9.18.0",
"invariant": "2.2.2",
"lodash": "4.17.4"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babel-types": {
@@ -966,14 +879,6 @@
"esutils": "2.0.2",
"lodash": "4.17.4",
"to-fast-properties": "1.0.3"
- },
- "dependencies": {
- "lodash": {
- "version": "4.17.4",
- "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
- "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=",
- "dev": true
- }
}
},
"babylon": {
@@ -1148,12 +1053,12 @@
}
},
"browserslist": {
- "version": "2.10.0",
- "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-2.10.0.tgz",
- "integrity": "sha512-WyvzSLsuAVPOjbljXnyeWl14Ae+ukAT8MUuagKVzIDvwBxl4UAwD1xqtyQs2eWYPGUKMeC3Ol62goqYuKqTTcw==",
+ "version": "2.11.0",
+ "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-2.11.0.tgz",
+ "integrity": "sha512-mNYp0RNeu1xueGuJFSXkU+K0nH+dBE/gcjtyhtNKfU8hwdrVIfoA7i5iFSjOmzkGdL2QaO7YX9ExiVPE7AY9JA==",
"dev": true,
"requires": {
- "caniuse-lite": "1.0.30000784",
+ "caniuse-lite": "1.0.30000787",
"electron-to-chromium": "1.3.30"
}
},
@@ -1205,22 +1110,6 @@
"ssri": "5.0.0",
"unique-filename": "1.1.0",
"y18n": "3.2.1"
- },
- "dependencies": {
- "glob": {
- "version": "7.1.2",
- "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz",
- "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
- "dev": true,
- "requires": {
- "fs.realpath": "1.0.0",
- "inflight": "1.0.6",
- "inherits": "2.0.3",
- "minimatch": "3.0.4",
- "once": "1.4.0",
- "path-is-absolute": "1.0.1"
- }
- }
}
},
"cachedir": {
@@ -1249,9 +1138,9 @@
"dev": true
},
"caniuse-lite": {
- "version": "1.0.30000784",
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000784.tgz",
- "integrity": "sha1-EpztdOmhKApEGIC2zSvOMO9Z5sA=",
+ "version": "1.0.30000787",
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000787.tgz",
+ "integrity": "sha1-p2xPodasAGQER+yDwefGsz3WFcU=",
"dev": true
},
"caseless": {
@@ -1373,6 +1262,14 @@
"center-align": "0.1.3",
"right-align": "0.1.3",
"wordwrap": "0.0.2"
+ },
+ "dependencies": {
+ "wordwrap": {
+ "version": "0.0.2",
+ "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.2.tgz",
+ "integrity": "sha1-t5Zpu0LstAn4PVg8rVLKF+qhZD8=",
+ "dev": true
+ }
}
},
"co": {
@@ -1445,11 +1342,40 @@
"word-wrap": "1.2.3"
}
},
+ "glob": {
+ "version": "7.1.1",
+ "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz",
+ "integrity": "sha1-gFIR3wT6rxxjo2ADBs31reULLsg=",
+ "dev": true,
+ "requires": {
+ "fs.realpath": "1.0.0",
+ "inflight": "1.0.6",
+ "inherits": "2.0.3",
+ "minimatch": "3.0.4",
+ "once": "1.4.0",
+ "path-is-absolute": "1.0.1"
+ }
+ },
"lodash": {
"version": "4.17.2",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.2.tgz",
"integrity": "sha1-NKMFW6vgTOQkZ7YH1wAHLH/2v0I=",
"dev": true
+ },
+ "minimist": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
+ "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
+ "dev": true
+ },
+ "path-exists": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz",
+ "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=",
+ "dev": true,
+ "requires": {
+ "pinkie-promise": "2.0.1"
+ }
}
}
},
@@ -1813,8 +1739,16 @@
"integrity": "sha512-H6PmeeUcZloWtdt4DAkFyzFL94arpHr3NOwwmVILFiy+9Qd4JTxxXrzfyGk/lmct2qVGBwTSwSXagqu2BxmWig==",
"dev": true,
"requires": {
- "acorn": "5.2.1",
+ "acorn": "5.3.0",
"defined": "1.0.0"
+ },
+ "dependencies": {
+ "acorn": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.3.0.tgz",
+ "integrity": "sha512-Yej+zOJ1Dm/IMZzzj78OntP/r3zHEaKcyNoU2lAaxPtrseM6rF0xwqoz5Q5ysAiED9hTjI2hgtvLXitlCN1/Ug==",
+ "dev": true
+ }
}
},
"diffie-hellman": {
@@ -2094,15 +2028,6 @@
"esutils": "2.0.2",
"optionator": "0.8.2",
"source-map": "0.5.7"
- },
- "dependencies": {
- "esprima": {
- "version": "3.1.3",
- "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz",
- "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=",
- "dev": true,
- "optional": true
- }
}
},
"escope": {
@@ -2134,6 +2059,14 @@
"marked": "0.3.6",
"minimist": "1.2.0",
"taffydb": "2.7.2"
+ },
+ "dependencies": {
+ "minimist": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
+ "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
+ "dev": true
+ }
}
},
"esdoc-accessor-plugin": {
@@ -2230,6 +2163,12 @@
"repeating": "1.1.3"
}
},
+ "minimist": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
+ "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
+ "dev": true
+ },
"repeating": {
"version": "1.1.3",
"resolved": "https://registry.npmjs.org/repeating/-/repeating-1.1.3.tgz",
@@ -2278,10 +2217,10 @@
"integrity": "sha1-H5h0xqfCvr+a05fDzrdcnGnaurE=",
"dev": true
},
- "esprima-fb": {
- "version": "15001.1.0-dev-harmony-fb",
- "resolved": "https://registry.npmjs.org/esprima-fb/-/esprima-fb-15001.1.0-dev-harmony-fb.tgz",
- "integrity": "sha1-MKlHMDxrjV6VW+4rmbHSMyBqaQE=",
+ "esprima": {
+ "version": "3.1.3",
+ "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz",
+ "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=",
"dev": true
},
"esrecurse": {
@@ -2653,9 +2592,9 @@
}
},
"glob": {
- "version": "7.1.1",
- "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz",
- "integrity": "sha1-gFIR3wT6rxxjo2ADBs31reULLsg=",
+ "version": "7.1.2",
+ "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz",
+ "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
"dev": true,
"requires": {
"fs.realpath": "1.0.0",
@@ -3261,15 +3200,6 @@
"webidl-conversions": "2.0.1",
"whatwg-url-compat": "0.6.5",
"xml-name-validator": "2.0.1"
- },
- "dependencies": {
- "acorn": {
- "version": "2.7.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-2.7.0.tgz",
- "integrity": "sha1-q259nYhqrKiwhbwzEreaGYQz8Oc=",
- "dev": true,
- "optional": true
- }
}
},
"jsesc": {
@@ -3345,6 +3275,12 @@
"source-map": "0.4.4"
},
"dependencies": {
+ "esprima-fb": {
+ "version": "15001.1.0-dev-harmony-fb",
+ "resolved": "https://registry.npmjs.org/esprima-fb/-/esprima-fb-15001.1.0-dev-harmony-fb.tgz",
+ "integrity": "sha1-MKlHMDxrjV6VW+4rmbHSMyBqaQE=",
+ "dev": true
+ },
"object-assign": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz",
@@ -3416,6 +3352,14 @@
"parse-json": "2.2.0",
"pify": "2.3.0",
"strip-bom": "3.0.0"
+ },
+ "dependencies": {
+ "pify": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
+ "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=",
+ "dev": true
+ }
}
},
"loader-runner": {
@@ -3443,14 +3387,6 @@
"requires": {
"p-locate": "2.0.0",
"path-exists": "3.0.0"
- },
- "dependencies": {
- "path-exists": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
- "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=",
- "dev": true
- }
}
},
"lodash": {
@@ -3578,14 +3514,6 @@
"dev": true,
"requires": {
"pify": "3.0.0"
- },
- "dependencies": {
- "pify": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz",
- "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=",
- "dev": true
- }
}
},
"marked": {
@@ -3715,9 +3643,9 @@
}
},
"minimist": {
- "version": "1.2.0",
- "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
- "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
+ "version": "0.0.8",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
+ "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
"dev": true
},
"mississippi": {
@@ -3745,14 +3673,6 @@
"dev": true,
"requires": {
"minimist": "0.0.8"
- },
- "dependencies": {
- "minimist": {
- "version": "0.0.8",
- "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
- "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
- "dev": true
- }
}
},
"move-concurrently": {
@@ -3933,15 +3853,6 @@
"prelude-ls": "1.1.2",
"type-check": "0.3.2",
"wordwrap": "1.0.0"
- },
- "dependencies": {
- "wordwrap": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz",
- "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=",
- "dev": true,
- "optional": true
- }
}
},
"os-browserify": {
@@ -3986,10 +3897,13 @@
"dev": true
},
"p-limit": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.1.0.tgz",
- "integrity": "sha1-sH/y2aXYi+yAYDWJWiurZqJ5iLw=",
- "dev": true
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.2.0.tgz",
+ "integrity": "sha512-Y/OtIaXtUPr4/YpMv1pCL5L5ed0rumAaAeBSj12F+bSlMdys7i8oQF/GUJmfpTS/QoaRrS/k6pma29haJpsMng==",
+ "dev": true,
+ "requires": {
+ "p-try": "1.0.0"
+ }
},
"p-locate": {
"version": "2.0.0",
@@ -3997,9 +3911,15 @@
"integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
"dev": true,
"requires": {
- "p-limit": "1.1.0"
+ "p-limit": "1.2.0"
}
},
+ "p-try": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz",
+ "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=",
+ "dev": true
+ },
"pad-right": {
"version": "0.2.2",
"resolved": "https://registry.npmjs.org/pad-right/-/pad-right-0.2.2.tgz",
@@ -4099,13 +4019,10 @@
"dev": true
},
"path-exists": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz",
- "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=",
- "dev": true,
- "requires": {
- "pinkie-promise": "2.0.1"
- }
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
+ "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=",
+ "dev": true
},
"path-is-absolute": {
"version": "1.0.1",
@@ -4132,6 +4049,14 @@
"dev": true,
"requires": {
"pify": "2.3.0"
+ },
+ "dependencies": {
+ "pify": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
+ "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=",
+ "dev": true
+ }
}
},
"pbkdf2": {
@@ -4155,9 +4080,9 @@
"optional": true
},
"pify": {
- "version": "2.3.0",
- "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
- "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=",
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz",
+ "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=",
"dev": true
},
"pinkie": {
@@ -4440,14 +4365,6 @@
"esprima": "3.1.3",
"private": "0.1.8",
"source-map": "0.5.7"
- },
- "dependencies": {
- "esprima": {
- "version": "3.1.3",
- "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz",
- "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=",
- "dev": true
- }
}
},
"rechoir": {
@@ -4657,7 +4574,7 @@
"integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==",
"dev": true,
"requires": {
- "glob": "7.1.1"
+ "glob": "7.1.2"
}
},
"ripemd160": {
@@ -4778,7 +4695,7 @@
"integrity": "sha1-N5zM+1a5HIYB5HkzVutTgpJN6a0=",
"dev": true,
"requires": {
- "glob": "7.1.1",
+ "glob": "7.1.2",
"interpret": "1.1.0",
"rechoir": "0.6.2"
}
@@ -5299,7 +5216,7 @@
"integrity": "sha512-fxxKXoicjdXNUMY7LIdY89tkJJJ0m1Oo8PQutZ5rLgWbV5QVKI15Cn7+/IHnRTd3vfKfiwBx6SBqlorAuNA8LA==",
"dev": true,
"requires": {
- "acorn": "5.2.1",
+ "acorn": "5.3.0",
"acorn-dynamic-import": "2.0.2",
"ajv": "5.5.2",
"ajv-keywords": "2.1.1",
@@ -5323,6 +5240,12 @@
"yargs": "8.0.2"
},
"dependencies": {
+ "acorn": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.3.0.tgz",
+ "integrity": "sha512-Yej+zOJ1Dm/IMZzzj78OntP/r3zHEaKcyNoU2lAaxPtrseM6rF0xwqoz5Q5ysAiED9hTjI2hgtvLXitlCN1/Ug==",
+ "dev": true
+ },
"supports-color": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-4.5.0.tgz",
@@ -5469,10 +5392,11 @@
"dev": true
},
"wordwrap": {
- "version": "0.0.2",
- "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.2.tgz",
- "integrity": "sha1-t5Zpu0LstAn4PVg8rVLKF+qhZD8=",
- "dev": true
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz",
+ "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=",
+ "dev": true,
+ "optional": true
},
"worker-farm": {
"version": "1.5.2",
diff --git a/src/config/configMgr.js b/src/config/configMgr.js
index 4140a79..adc8a57 100644
--- a/src/config/configMgr.js
+++ b/src/config/configMgr.js
@@ -1,7 +1,7 @@
// Created by xiazeyu.
/**
- * @description The container of configeration.
+ * @description The manager of configeration.
*/
@@ -9,7 +9,16 @@
import _ from 'lodash';
+/**
+ * The container of current configs
+ * @type {Object}
+ */
+
let currConfig = {};
+/**
+ * Default settings for defaulter
+ * @type {Object}
+ */
const defaultOptions = {
model: {
@@ -49,9 +58,14 @@ const defaultOptions = {
_: true,
}
+/**
+ * Apply users function, make the full settings
+ * @param {Object} userConfig User's custom config
+ */
+
function configApplyer(userConfig){
- if (!(_.has(userConfig, '_'))){
+ if (_.has(userConfig, '_')){
import(/* webpackMode: "lazy" */ './configValidater').then(f => {
f.configValidater(userConfig);
}).catch(err => {
diff --git a/src/config/configValidater.js b/src/config/configValidater.js
index 6f719e1..365db33 100644
--- a/src/config/configValidater.js
+++ b/src/config/configValidater.js
@@ -1,7 +1,7 @@
// Created by xiazeyu.
/**
- * @description the validater for user's config
+ * @description The validater function for user's config.
*/
diff --git a/src/index.js b/src/index.js
index 4fe2f59..b10aab6 100644
--- a/src/index.js
+++ b/src/index.js
@@ -5,7 +5,7 @@
////////////////////////////////////
/**
- * @description The entry point of live2d-widget
+ * @description The entry point of live2d-widget.
*/
@@ -16,10 +16,10 @@ import { config, configApplyer }from './config/configMgr';
/**
* The public entry point
- * @param {Object} userConfig User's config
+ * @param {Object} userConfig User's custom config
*/
-export function init(userConfig){
+function init(userConfig){
userConfig = typeof userConfig === 'undefined' ? {} : userConfig;
@@ -42,3 +42,7 @@ export function init(userConfig){
});
}
+
+export {
+ init,
+}
diff --git a/src/wpPublicPath.js b/src/wpPublicPath.js
index 198fdb1..3020ef1 100644
--- a/src/wpPublicPath.js
+++ b/src/wpPublicPath.js
@@ -1,5 +1,5 @@
/**
- * @description Automatic locate the publicPath for webpack
+ * @description Automatic locate the publicPath and set it up for webpack.
*/
@@ -7,9 +7,9 @@
/**
* Get current script path
- * @return {String} the accessable path of current script
+ * @return {String} The accessable path of current script
* @example
- * get 'dev/' or 'https'
+ * get 'dev/' or 'https://www.host.com/test/js/'
*/
function getCurrentPath(){
@@ -31,13 +31,17 @@ function getCurrentPath(){
// console.log(e);
let stack = e.stack || e.sourceURL || e.stacktrace,
- rExtractUri = /(?:http|https|file):\/\/.*?\/.+?.js/,
- absPath = rExtractUri.exec(stack);
- currentScriptPath = absPath[0] || '';
- }
+ rExtractUri = /(file:\/{3}\w:)(\/[^\/]*){3}\//;
+ // TODO: Fix wrong RegExp: rExtractUri
+ let absPath = rExtractUri.exec(stack);
+ currentScriptPath = absPath[0];
+
+ if(currentScriptPath === ''){
+ rExtractUri = /(?:http|https|file):\/\/.*?\/.+?.js/;
+ absPath = rExtractUri.exec(stack);
+ currentScriptPath = absPath[0];
+ }
- if (currentScriptPath === null){
- throw 'Cannot get currentScriptPath for wpPublicPath';
}
return currentScriptPath;
@@ -50,3 +54,7 @@ __webpack_public_path__ = getCurrentPath();
if (process.env.NODE_ENV === 'development'){
console.log(`wpPP: publicPath: ${__webpack_public_path__}`);
}
+
+export {
+ getCurrentPath,
+}